|
|
|
@ -84,6 +84,7 @@
|
|
|
|
|
:formatter="dateFormat"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
|
|
|
|
|
<!-- <el-table-column
|
|
|
|
|
prop="dyLevel"
|
|
|
|
|
label="电压等级"
|
|
|
|
@ -101,14 +102,14 @@
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="towerName"
|
|
|
|
|
label="杆塔名称"
|
|
|
|
|
min-width="115"
|
|
|
|
|
min-width="145"
|
|
|
|
|
:show-overflow-tooltip="true"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column
|
|
|
|
|
prop="displayName"
|
|
|
|
|
label="设备名称"
|
|
|
|
|
min-width="95"
|
|
|
|
|
min-width="145"
|
|
|
|
|
:show-overflow-tooltip="true"
|
|
|
|
|
>
|
|
|
|
|
</el-table-column>
|
|
|
|
@ -140,8 +141,8 @@
|
|
|
|
|
</el-table-column>
|
|
|
|
|
<el-table-column label="是否已读" min-width="95" fixed="right">
|
|
|
|
|
<template slot-scope="scope">
|
|
|
|
|
<span v-if="scope.row.isread == 0">未读</span>
|
|
|
|
|
<span v-if="scope.row.isread == 1">已读</span>
|
|
|
|
|
<span v-if="scope.row.isread == 0 || isreadshow">未读</span>
|
|
|
|
|
<span v-if="scope.row.isread == 1 || isreadshow">已读</span>
|
|
|
|
|
</template>
|
|
|
|
|
</el-table-column>
|
|
|
|
|
</el-table>
|
|
|
|
@ -170,7 +171,7 @@
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
import { getSearchInfo, getAlarmList } from "@/utils/api/index";
|
|
|
|
|
import { getSearchInfo, getAlarmList, readAlarm } from "@/utils/api/index";
|
|
|
|
|
import moment from "moment";
|
|
|
|
|
export default {
|
|
|
|
|
data() {
|
|
|
|
@ -193,6 +194,7 @@ export default {
|
|
|
|
|
pageSize: 20, // 每页数量
|
|
|
|
|
total: 0, //总条数
|
|
|
|
|
loading: false,
|
|
|
|
|
isreadshow: false,
|
|
|
|
|
};
|
|
|
|
|
},
|
|
|
|
|
mounted() {
|
|
|
|
@ -286,6 +288,15 @@ export default {
|
|
|
|
|
console.log(row);
|
|
|
|
|
this.photoPic = row.path;
|
|
|
|
|
//未读变已读
|
|
|
|
|
readAlarm({
|
|
|
|
|
id: row.id,
|
|
|
|
|
})
|
|
|
|
|
.then((res) => {
|
|
|
|
|
console.log(res);
|
|
|
|
|
})
|
|
|
|
|
.catch((err) => {
|
|
|
|
|
console.log(err);
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
dateFormat(row, column) {
|
|
|
|
|
var date = row[column.property];
|
|
|
|
|