同步现场代码
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<!-- 变电站 -->
|
||||
<el-dialog draggable title="变电站详情" v-model="dialogVisible" width="1400px" :before-close="handleClose">
|
||||
<el-dialog draggable title="变电站统计" v-model="dialogVisible" width="1400px" :before-close="handleClose">
|
||||
<el-row style="height: 300px" :gutter="20">
|
||||
<el-col :span="12">
|
||||
<div class="title">
|
||||
@@ -39,16 +39,21 @@
|
||||
</div>
|
||||
|
||||
<div class="pie">
|
||||
<MyEChart v-for="item in picEChart" class="MyEChart" :options="item" />
|
||||
<MyEChart
|
||||
v-for="(item, i) in picEChart"
|
||||
:style="i == 3 ? `margin-left: 20%;` : ``"
|
||||
class="MyEChart"
|
||||
:options="item"
|
||||
/>
|
||||
</div>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<div>
|
||||
<div class="title mb10">
|
||||
<span>变电站详细列表</span>
|
||||
<span>区域变电站统计</span>
|
||||
</div>
|
||||
<vxe-table v-bind="defaultAttribute" ref="vxeRef" height="300px" :data="tableData">
|
||||
<vxe-column field="name" title="所属区域" />
|
||||
<vxe-column field="name" title="区域" />
|
||||
<vxe-column field="num" title="变电站总数" />
|
||||
<vxe-column field="num1" title="无污染数量" :formatter="formatter" />
|
||||
<vxe-column field="num2" title="轻微污染数量" :formatter="formatter" />
|
||||
@@ -96,23 +101,11 @@ const open = async (row: any) => {
|
||||
// 污染
|
||||
contaminateC()
|
||||
// 列表
|
||||
getPollutionAlarmList(rowList.value).then(res => {
|
||||
tableData.value = res.data.map((item: any) => {
|
||||
return {
|
||||
name: item[0],
|
||||
num: item[1],
|
||||
num1: item[2],
|
||||
num2: item[3],
|
||||
num3: item[4],
|
||||
num4: item[5],
|
||||
num5: item[5]
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
dialogVisible.value = true
|
||||
}
|
||||
const contaminateC = () => {
|
||||
// rowList.value.deviceInfoParam.ids=[contaminate.value]
|
||||
getPollutionAlarmData({ ...rowList.value, ids: [contaminate.value] }).then(res => {
|
||||
let data = []
|
||||
|
||||
@@ -213,14 +206,15 @@ const contaminateC = () => {
|
||||
show: false
|
||||
},
|
||||
axisLabel: {
|
||||
distance: 5,
|
||||
color: '#666',
|
||||
fontSize: 12,
|
||||
formatter: function (value: any) {
|
||||
if (value === 0 || value === 100) {
|
||||
return value + '%'
|
||||
}
|
||||
}
|
||||
show: false
|
||||
// distance: 5,
|
||||
// color: '#666',
|
||||
// fontSize: 12,
|
||||
// formatter: function (value: any) {
|
||||
// if (value === 0 || value === 100) {
|
||||
// return value + '%'
|
||||
// }
|
||||
// }
|
||||
},
|
||||
anchor: {
|
||||
show: false,
|
||||
@@ -260,6 +254,19 @@ const contaminateC = () => {
|
||||
}
|
||||
})
|
||||
})
|
||||
getPollutionAlarmList({ ...rowList.value, ids: [contaminate.value] }).then(res => {
|
||||
tableData.value = res.data.map((item: any) => {
|
||||
return {
|
||||
name: item[0],
|
||||
num: item[1],
|
||||
num1: item[2],
|
||||
num2: item[3],
|
||||
num3: item[4],
|
||||
num4: item[5],
|
||||
num5: item[5]
|
||||
}
|
||||
})
|
||||
})
|
||||
}
|
||||
const analysis = (e: any) => {
|
||||
let time = rowList.value.searchBeginTime?.slice(0, 4) + `-01-01`
|
||||
|
||||
Reference in New Issue
Block a user