2024-11-11 14:40:40 +08:00
|
|
|
<!--
|
|
|
|
|
* @Author: SunTao 328867980@qq.com
|
|
|
|
|
* @Date: 2024-11-08 09:40:18
|
|
|
|
|
* @LastEditors: SunTao 328867980@qq.com
|
2024-11-14 17:43:24 +08:00
|
|
|
* @LastEditTime: 2024-11-14 15:54:12
|
2024-11-11 14:40:40 +08:00
|
|
|
* @FilePath: \znxjxt-ui\src\views\big-screen\disease-components\inspection-vehicles.vue
|
|
|
|
|
* @Description: 总览大屏-巡检车辆
|
|
|
|
|
-->
|
|
|
|
|
|
|
|
|
|
<template>
|
|
|
|
|
<div class="content">
|
|
|
|
|
<div class="inspection-top">
|
2024-11-13 15:37:25 +08:00
|
|
|
<div class="top-div inspection-div-car">
|
|
|
|
|
<div>
|
|
|
|
|
<span>{{ carNum }}</span
|
|
|
|
|
>辆
|
|
|
|
|
</div>
|
2024-11-11 14:40:40 +08:00
|
|
|
</div>
|
2024-11-13 15:37:25 +08:00
|
|
|
<div class="top-div inspection-div-online">
|
|
|
|
|
<div>
|
|
|
|
|
<span>{{ onlineNum }}</span
|
|
|
|
|
>辆
|
|
|
|
|
</div>
|
2024-11-11 14:40:40 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="inspection-bottom">
|
|
|
|
|
<el-input placeholder="请输入车牌号" v-model="tableInput">
|
|
|
|
|
<template slot="append"
|
2024-11-13 15:37:25 +08:00
|
|
|
><el-button
|
|
|
|
|
slot="append"
|
|
|
|
|
icon="el-icon-search"
|
2024-11-14 17:43:24 +08:00
|
|
|
clearable
|
2024-11-13 15:37:25 +08:00
|
|
|
@click="getTableData"
|
|
|
|
|
></el-button
|
2024-11-11 14:40:40 +08:00
|
|
|
></template>
|
|
|
|
|
</el-input>
|
|
|
|
|
<!-- 列表 -->
|
2024-11-13 15:37:25 +08:00
|
|
|
<el-table
|
|
|
|
|
:data="inspectionTableData"
|
|
|
|
|
header-row-class-name="headerRow"
|
|
|
|
|
row-class-name="bodayRow"
|
|
|
|
|
style="width: 100%; background: none"
|
|
|
|
|
height="285"
|
|
|
|
|
>
|
|
|
|
|
<el-table-column prop="plateNo" label="车牌号码"> </el-table-column>
|
2024-11-14 17:43:24 +08:00
|
|
|
<el-table-column prop="status" label="状态"> </el-table-column>
|
2024-11-11 14:40:40 +08:00
|
|
|
<el-table-column prop="pci" label="操作">
|
|
|
|
|
<template slot-scope="scope">
|
2024-11-13 15:37:25 +08:00
|
|
|
<el-popover
|
|
|
|
|
popper-class="scope-popover"
|
|
|
|
|
placement="left"
|
|
|
|
|
width="auto"
|
|
|
|
|
trigger="click"
|
|
|
|
|
>
|
|
|
|
|
<div class="table-detail">
|
|
|
|
|
<div>
|
|
|
|
|
<span class="name">车牌号码:</span>
|
|
|
|
|
<span class="value">{{ scope.row.plateNo }}</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div>
|
2024-11-14 17:43:24 +08:00
|
|
|
<span class="name">设备编号:</span>
|
2024-11-13 15:37:25 +08:00
|
|
|
<span class="value">{{ scope.row.appid }}</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div>
|
2024-11-14 17:43:24 +08:00
|
|
|
<span class="name">车辆状态:</span>
|
|
|
|
|
<span class="value">{{ scope.row.status }}</span>
|
2024-11-13 15:37:25 +08:00
|
|
|
</div>
|
|
|
|
|
<div>
|
2024-11-14 17:43:24 +08:00
|
|
|
<span class="name">网络连接:</span>
|
2024-11-13 15:37:25 +08:00
|
|
|
<span class="value"></span>
|
|
|
|
|
</div>
|
|
|
|
|
<div>
|
2024-11-14 17:43:24 +08:00
|
|
|
<span class="name">设备状态:</span>
|
2024-11-13 15:37:25 +08:00
|
|
|
<span class="value"></span>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<el-button
|
|
|
|
|
slot="reference"
|
|
|
|
|
size="mini"
|
|
|
|
|
type="text"
|
|
|
|
|
style="margin-right: 0.6rem"
|
|
|
|
|
@click="detailDefect(scope.row)"
|
|
|
|
|
>详情
|
|
|
|
|
</el-button>
|
|
|
|
|
</el-popover>
|
|
|
|
|
|
2024-11-11 14:40:40 +08:00
|
|
|
<el-button
|
2024-11-13 15:37:25 +08:00
|
|
|
disabled
|
2024-11-11 14:40:40 +08:00
|
|
|
size="mini"
|
|
|
|
|
type="text"
|
|
|
|
|
@click="followCar(scope.row)"
|
|
|
|
|
v-hasPermi="['system:defect:edit']"
|
|
|
|
|
>跟车
|
|
|
|
|
</el-button>
|
|
|
|
|
<el-button
|
2024-11-13 15:37:25 +08:00
|
|
|
disabled
|
2024-11-11 14:40:40 +08:00
|
|
|
size="mini"
|
|
|
|
|
type="text"
|
|
|
|
|
@click="videoDelete(scope.row)"
|
|
|
|
|
v-hasPermi="['system:defect:remove']"
|
|
|
|
|
>视频
|
|
|
|
|
</el-button>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
</el-table>
|
|
|
|
|
<!-- 分页组件 -->
|
2024-11-13 15:37:25 +08:00
|
|
|
<!-- <div class="pagination-part">
|
2024-11-11 14:40:40 +08:00
|
|
|
<el-pagination
|
|
|
|
|
background
|
|
|
|
|
:pager-count="5"
|
|
|
|
|
:current-page.sync="pagination.page"
|
|
|
|
|
@current-change="handleCurrentChange"
|
|
|
|
|
:page-sizes="[10, 20, 30, 40]"
|
|
|
|
|
:page-size.sync="pagination.size"
|
|
|
|
|
layout="prev, pager, next"
|
|
|
|
|
:total="tableTotal"
|
|
|
|
|
>
|
|
|
|
|
</el-pagination>
|
2024-11-13 15:37:25 +08:00
|
|
|
</div> -->
|
2024-11-11 14:40:40 +08:00
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
2024-11-13 15:37:25 +08:00
|
|
|
import { getCarList } from "@/api/xj/screen/disease-screen";
|
2024-11-11 14:40:40 +08:00
|
|
|
export default {
|
|
|
|
|
name: "InspectionVehicles",
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
// 车辆总数
|
2024-11-13 15:37:25 +08:00
|
|
|
carNum: 0,
|
2024-11-11 14:40:40 +08:00
|
|
|
// 在线车辆数
|
2024-11-13 15:37:25 +08:00
|
|
|
onlineNum: 0,
|
2024-11-11 14:40:40 +08:00
|
|
|
// 车牌号输入绑定
|
|
|
|
|
tableInput: "",
|
|
|
|
|
// 下方列表数据
|
|
|
|
|
inspectionTableData: [],
|
|
|
|
|
// 分页数据绑定
|
2024-11-13 15:37:25 +08:00
|
|
|
// pagination: {
|
|
|
|
|
// page: 1,
|
|
|
|
|
// size: 10,
|
|
|
|
|
// },
|
2024-11-11 14:40:40 +08:00
|
|
|
// 分页总数
|
2024-11-13 15:37:25 +08:00
|
|
|
tableTotal: 0,
|
2024-11-11 14:40:40 +08:00
|
|
|
};
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|
this.getTableData();
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
/* 获取表格数据 */
|
|
|
|
|
getTableData() {
|
2024-11-14 17:43:24 +08:00
|
|
|
getCarList({ no: this.tableInput }).then(({ code, data }) => {
|
2024-11-13 15:37:25 +08:00
|
|
|
if (code === 200) {
|
|
|
|
|
this.carNum = data.total;
|
|
|
|
|
this.tableTotal = data.total;
|
|
|
|
|
this.onlineNum = data.online;
|
|
|
|
|
this.inspectionTableData = data.rows;
|
|
|
|
|
}
|
|
|
|
|
});
|
2024-11-11 14:40:40 +08:00
|
|
|
},
|
|
|
|
|
|
|
|
|
|
/* 表格详情事件 */
|
|
|
|
|
detailDefect(val) {},
|
|
|
|
|
|
|
|
|
|
/* 表格跟车事件 */
|
|
|
|
|
followCar(val) {},
|
|
|
|
|
|
|
|
|
|
/* 表格视频事件 */
|
|
|
|
|
videoDelete(val) {},
|
|
|
|
|
|
|
|
|
|
/* 页码修改事件 */
|
2024-11-13 15:37:25 +08:00
|
|
|
// handleCurrentChange(arg) {
|
|
|
|
|
// this.pagination.page = arg;
|
|
|
|
|
// this.getTableData();
|
|
|
|
|
// },
|
2024-11-11 14:40:40 +08:00
|
|
|
},
|
|
|
|
|
};
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
|
.content {
|
|
|
|
|
width: 100%;
|
|
|
|
|
height: 100%;
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
|
|
|
|
|
.inspection-top {
|
|
|
|
|
width: 100%;
|
2024-11-13 15:37:25 +08:00
|
|
|
height: 20%;
|
2024-11-11 14:40:40 +08:00
|
|
|
padding: 0.5rem;
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-around;
|
|
|
|
|
|
|
|
|
|
.top-div {
|
|
|
|
|
width: 45%;
|
|
|
|
|
height: 100%;
|
2024-11-13 15:37:25 +08:00
|
|
|
line-height: 6rem;
|
2024-11-11 14:40:40 +08:00
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
flex-direction: column;
|
|
|
|
|
justify-content: space-around;
|
2024-11-13 15:37:25 +08:00
|
|
|
font-size: 0.6rem;
|
|
|
|
|
|
|
|
|
|
span {
|
|
|
|
|
font-size: 1rem;
|
|
|
|
|
font-family: "DouYu";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.inspection-div-car {
|
|
|
|
|
background-image: url("~@/assets/screen/index/inspection-div-car.png");
|
|
|
|
|
background-repeat: no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.inspection-div-online {
|
|
|
|
|
background-image: url("~@/assets/screen/index/inspection-div-online.png");
|
|
|
|
|
background-repeat: no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
2024-11-11 14:40:40 +08:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2024-11-13 15:37:25 +08:00
|
|
|
::v-deep .inspection-bottom {
|
2024-11-11 14:40:40 +08:00
|
|
|
width: 100%;
|
2024-11-13 15:37:25 +08:00
|
|
|
height: 80%;
|
2024-11-11 14:40:40 +08:00
|
|
|
padding: 1rem 0.5rem;
|
|
|
|
|
|
2024-11-13 15:37:25 +08:00
|
|
|
.el-input {
|
2024-11-11 14:40:40 +08:00
|
|
|
margin-bottom: 0.5rem;
|
|
|
|
|
.el-input__inner {
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
background-color: transparent;
|
2024-11-13 15:37:25 +08:00
|
|
|
border-color: rgb(69, 109, 211, 0.5);
|
2024-11-11 14:40:40 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.el-input-group__append {
|
|
|
|
|
background-color: transparent;
|
|
|
|
|
color: #ffffff;
|
2024-11-13 15:37:25 +08:00
|
|
|
border-color: rgb(69, 109, 211, 0.5);
|
2024-11-11 14:40:40 +08:00
|
|
|
|
|
|
|
|
&:hover {
|
|
|
|
|
background-color: #3c5a8a;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2024-11-13 15:37:25 +08:00
|
|
|
// 表格最下方border
|
|
|
|
|
.el-table::before {
|
|
|
|
|
background-color: transparent;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 隐藏滚动条
|
|
|
|
|
.el-table__body-wrapper::-webkit-scrollbar {
|
|
|
|
|
/*width: 0;宽度为0隐藏*/
|
|
|
|
|
width: 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 表头行
|
|
|
|
|
.headerRow {
|
|
|
|
|
background: url("~@/assets/screen/traffic/emergency-top.png") no-repeat;
|
|
|
|
|
background-size: 100%;
|
|
|
|
|
|
2024-11-11 14:40:40 +08:00
|
|
|
th {
|
|
|
|
|
color: #ffffff;
|
2024-11-13 15:37:25 +08:00
|
|
|
background: none;
|
|
|
|
|
border-color: transparent;
|
2024-11-11 14:40:40 +08:00
|
|
|
}
|
2024-11-13 15:37:25 +08:00
|
|
|
}
|
2024-11-11 14:40:40 +08:00
|
|
|
|
2024-11-13 15:37:25 +08:00
|
|
|
// 表格行
|
|
|
|
|
.bodayRow {
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
background: none;
|
2024-11-11 14:40:40 +08:00
|
|
|
|
2024-11-13 15:37:25 +08:00
|
|
|
&:nth-child(2n) {
|
|
|
|
|
background: #113463;
|
2024-11-11 14:40:40 +08:00
|
|
|
}
|
|
|
|
|
|
2024-11-13 15:37:25 +08:00
|
|
|
// 表格内下划线
|
|
|
|
|
td {
|
|
|
|
|
// border-color: transparent;
|
|
|
|
|
border-bottom: 1px dashed rgb(115, 115, 116);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 去除鼠标移动高亮
|
|
|
|
|
&:hover > td {
|
|
|
|
|
background-color: transparent;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.el-table__cell {
|
|
|
|
|
padding: 0.2rem 0;
|
|
|
|
|
}
|
2024-11-11 14:40:40 +08:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* 分页样式 */
|
|
|
|
|
.pagination-part {
|
|
|
|
|
width: 100%;
|
|
|
|
|
display: flex;
|
|
|
|
|
padding-top: 0.5rem;
|
|
|
|
|
justify-content: flex-end;
|
|
|
|
|
|
|
|
|
|
::v-deep .el-pagination {
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
.btn-prev,
|
|
|
|
|
.btn-next {
|
|
|
|
|
background-color: #6481aa;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
::v-deep .el-pager li {
|
|
|
|
|
background: transparent;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</style>
|
2024-11-13 15:37:25 +08:00
|
|
|
<style lang="scss">
|
|
|
|
|
/* 弹出层样式 */
|
|
|
|
|
.scope-popover {
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
background-color: #000000;
|
|
|
|
|
border-color: transparent;
|
|
|
|
|
}
|
|
|
|
|
</style>
|