|
@ -1,5 +1,5 @@ |
|
|
<template> |
|
|
<template> |
|
|
<div class='board_record'> |
|
|
<div class="board_record"> |
|
|
<!-- 搜索栏 --> |
|
|
<!-- 搜索栏 --> |
|
|
<div class="filter"> |
|
|
<div class="filter"> |
|
|
<div> |
|
|
<div> |
|
@ -11,17 +11,31 @@ |
|
|
</ButtonGradient> |
|
|
</ButtonGradient> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
<InputSearch ref="searchComp" style="width: 400px" :formList="searchFormList" |
|
|
<InputSearch |
|
|
:formConfigOptions="{ dFormData: { eventState: '0' } }" @handleSearch="handleSearch" /> |
|
|
ref="searchComp" |
|
|
|
|
|
style="width: 400px" |
|
|
|
|
|
:formList="searchFormList" |
|
|
|
|
|
:formConfigOptions="{ dFormData: { eventState: '0' } }" |
|
|
|
|
|
@handleSearch="handleSearch" |
|
|
|
|
|
/> |
|
|
</div> |
|
|
</div> |
|
|
<!-- 内容 --> |
|
|
<!-- 内容 --> |
|
|
<div class="body"> |
|
|
<div class="body"> |
|
|
|
|
|
|
|
|
<Table :data="tableData" height="75vh"> |
|
|
<Table :data="tableData" height="75vh"> |
|
|
<el-table-column label="序号" type="index" :index="indexMethod" width="100" align="center" |
|
|
<el-table-column |
|
|
header-align="center" /> |
|
|
label="序号" |
|
|
<ElTableColumn label="设备名称" show-overflow-tooltip prop="deviceName" header-align="center" /> |
|
|
type="index" |
|
|
|
|
|
:index="indexMethod" |
|
|
|
|
|
width="100" |
|
|
|
|
|
align="center" |
|
|
|
|
|
header-align="center" |
|
|
|
|
|
/> |
|
|
|
|
|
<ElTableColumn |
|
|
|
|
|
label="设备名称" |
|
|
|
|
|
show-overflow-tooltip |
|
|
|
|
|
prop="deviceName" |
|
|
|
|
|
header-align="center" |
|
|
|
|
|
/> |
|
|
<ElTableColumn label="设备类型" prop="deviceTypeName" /> |
|
|
<ElTableColumn label="设备类型" prop="deviceTypeName" /> |
|
|
<ElTableColumn label="方向" prop="directionName" /> |
|
|
<ElTableColumn label="方向" prop="directionName" /> |
|
|
<ElTableColumn label="安装位置" prop="installationSite" /> |
|
|
<ElTableColumn label="安装位置" prop="installationSite" /> |
|
@ -31,9 +45,27 @@ |
|
|
|
|
|
|
|
|
<ElTableColumn label="状态" width="150" prop="stateName" /> |
|
|
<ElTableColumn label="状态" width="150" prop="stateName" /> |
|
|
|
|
|
|
|
|
<ElTableColumn label="操作" width="130" align="center" v-hasPermi="['maintain:abnormal:updateStatus']"> |
|
|
<ElTableColumn |
|
|
|
|
|
label="操作" |
|
|
|
|
|
width="130" |
|
|
|
|
|
align="center" |
|
|
|
|
|
v-hasPermi="['maintain:abnormal:updateStatus']" |
|
|
|
|
|
> |
|
|
<template slot-scope="scope"> |
|
|
<template slot-scope="scope"> |
|
|
<ElButton type="text" v-if="scope.row.status==='0'" style="color: #00D1FF;" @click="showDisposal(scope.row)">处理</ElButton> |
|
|
<ElButton |
|
|
|
|
|
type="text" |
|
|
|
|
|
v-if="scope.row.status === '0'" |
|
|
|
|
|
style="color: #00d1ff" |
|
|
|
|
|
@click="showDisposal(scope.row)" |
|
|
|
|
|
>处理</ElButton |
|
|
|
|
|
> |
|
|
|
|
|
<ElButton |
|
|
|
|
|
type="text" |
|
|
|
|
|
v-if="scope.row.status === '0'" |
|
|
|
|
|
style="color: #00d1ff" |
|
|
|
|
|
@click="diagnosis(scope.row)" |
|
|
|
|
|
>诊断</ElButton |
|
|
|
|
|
> |
|
|
</template> |
|
|
</template> |
|
|
</ElTableColumn> |
|
|
</ElTableColumn> |
|
|
</Table> |
|
|
</Table> |
|
@ -41,9 +73,16 @@ |
|
|
|
|
|
|
|
|
<!-- 分页 --> |
|
|
<!-- 分页 --> |
|
|
<div class="footer"> |
|
|
<div class="footer"> |
|
|
<Pagination @current-change="initData" @size-change="onSizeChange" width="'100%'" |
|
|
<Pagination |
|
|
:page-sizes="[10, 20, 30, 40, 50]" :page-size="searchData.pageSize" :current-page.sync="searchData.pageNum" |
|
|
@current-change="initData" |
|
|
layout="total, sizes, prev, pager, next" :total="total"> |
|
|
@size-change="onSizeChange" |
|
|
|
|
|
width="'100%'" |
|
|
|
|
|
:page-sizes="[10, 20, 30, 40, 50]" |
|
|
|
|
|
:page-size="searchData.pageSize" |
|
|
|
|
|
:current-page.sync="searchData.pageNum" |
|
|
|
|
|
layout="total, sizes, prev, pager, next" |
|
|
|
|
|
:total="total" |
|
|
|
|
|
> |
|
|
</Pagination> |
|
|
</Pagination> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
@ -64,6 +103,7 @@ import Button from "@screen/components/Buttons/Button.vue"; |
|
|
import Form from "@screen/components/FormConfig"; |
|
|
import Form from "@screen/components/FormConfig"; |
|
|
import {deviceTypeOptions} from '@screen/utils/enum.js'; |
|
|
import {deviceTypeOptions} from '@screen/utils/enum.js'; |
|
|
import DialogWarning from '@screen/components/HeaderMenu/dialogWarn/DialogWarning.vue' |
|
|
import DialogWarning from '@screen/components/HeaderMenu/dialogWarn/DialogWarning.vue' |
|
|
|
|
|
import { re } from 'mathjs'; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
name: 'boardRecord', |
|
|
name: 'boardRecord', |
|
@ -91,6 +131,7 @@ export default { |
|
|
pageNum: 1 |
|
|
pageNum: 1 |
|
|
}, |
|
|
}, |
|
|
dialogWarningVisible: false, |
|
|
dialogWarningVisible: false, |
|
|
|
|
|
deviceTypeCount:"", |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
created() { |
|
|
created() { |
|
@ -119,6 +160,39 @@ export default { |
|
|
}, |
|
|
}, |
|
|
indexMethod(index) { |
|
|
indexMethod(index) { |
|
|
return this.searchData.pageSize*(this.searchData.pageNum-1) + index + 1; |
|
|
return this.searchData.pageSize*(this.searchData.pageNum-1) + index + 1; |
|
|
|
|
|
}, |
|
|
|
|
|
// diagnosis(row){ |
|
|
|
|
|
// const self = this; |
|
|
|
|
|
// request({ |
|
|
|
|
|
// url:`/business/switch/deviceDiagnostics`, |
|
|
|
|
|
// method:"post", |
|
|
|
|
|
// data:{ |
|
|
|
|
|
// ...row, |
|
|
|
|
|
// } |
|
|
|
|
|
// }).then((result)=>{ |
|
|
|
|
|
// if (result.code != 200) return Message.error(result?.msg); |
|
|
|
|
|
// this.deviceTypeCount=result.rows.data |
|
|
|
|
|
// }).this.$confirm(`诊断结果:`+deviceTypeCount) |
|
|
|
|
|
// }, |
|
|
|
|
|
diagnosis(row) { |
|
|
|
|
|
const self = this; |
|
|
|
|
|
request({ |
|
|
|
|
|
url: `/business/switch/deviceDiagnostics`, |
|
|
|
|
|
method: "post", |
|
|
|
|
|
data: { |
|
|
|
|
|
...row, |
|
|
|
|
|
} |
|
|
|
|
|
}).then((result) => { |
|
|
|
|
|
if (result.code != 200) { |
|
|
|
|
|
return Message.error(result?.msg); |
|
|
|
|
|
} |
|
|
|
|
|
self.deviceTypeCount = result.msg; |
|
|
|
|
|
self.$confirm(`诊断结果:` + self.deviceTypeCount,"诊断异常",{ |
|
|
|
|
|
type: "warning" |
|
|
|
|
|
}); |
|
|
|
|
|
}).catch((error) => { |
|
|
|
|
|
console.error("请求失败:", error); |
|
|
|
|
|
}); |
|
|
}, |
|
|
}, |
|
|
// |
|
|
// |
|
|
showDisposal(row){ |
|
|
showDisposal(row){ |
|
@ -141,6 +215,7 @@ export default { |
|
|
}) |
|
|
}) |
|
|
}).catch(function() {}); |
|
|
}).catch(function() {}); |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
// |
|
|
// |
|
|
|
|
|
|
|
|
initData() { |
|
|
initData() { |
|
@ -219,7 +294,8 @@ export default { |
|
|
margin: 4px; |
|
|
margin: 4px; |
|
|
} |
|
|
} |
|
|
::v-deep .el-carousel__indicators--horizontal { |
|
|
::v-deep .el-carousel__indicators--horizontal { |
|
|
line-height: 0; height: 16px; |
|
|
line-height: 0; |
|
|
|
|
|
height: 16px; |
|
|
.el-carousel__indicator--horizontal { |
|
|
.el-carousel__indicator--horizontal { |
|
|
padding: 7px 4px; |
|
|
padding: 7px 4px; |
|
|
} |
|
|
} |
|
|