2025-06-22 17:22:40 +08:00
|
|
|
|
<template>
|
2025-08-15 14:13:54 +08:00
|
|
|
|
<div v-loading="loading">
|
2025-09-25 17:58:22 +08:00
|
|
|
|
<el-card
|
2025-09-26 14:47:45 +08:00
|
|
|
|
v-for="(item,index) in list"
|
|
|
|
|
|
:key="index+'dbList'"
|
2025-09-25 17:58:22 +08:00
|
|
|
|
shadow="always"
|
2025-09-26 14:47:45 +08:00
|
|
|
|
class="sbjk-card-container list"
|
2025-09-25 17:58:22 +08:00
|
|
|
|
:class="{
|
2025-09-26 14:47:45 +08:00
|
|
|
|
'warning-card-container':item.emsCommunicationStatus && item.emsCommunicationStatus !== '0',
|
|
|
|
|
|
'running-card-container':item.emsCommunicationStatus === '0'
|
2025-09-10 09:54:29 +08:00
|
|
|
|
}"
|
2025-09-25 17:58:22 +08:00
|
|
|
|
>
|
|
|
|
|
|
<div slot="header">
|
2025-09-28 14:31:24 +08:00
|
|
|
|
<span class="large-title">{{index+1}}#{{ item.deviceName }}</span>
|
2025-09-25 17:58:22 +08:00
|
|
|
|
<div class="info">
|
|
|
|
|
|
<div>
|
|
|
|
|
|
{{
|
|
|
|
|
|
$store.state.ems.communicationStatusOptions[
|
2025-09-26 14:47:45 +08:00
|
|
|
|
item.emsCommunicationStatus
|
2025-09-25 17:58:22 +08:00
|
|
|
|
]
|
|
|
|
|
|
}}
|
|
|
|
|
|
</div>
|
2025-09-26 14:47:45 +08:00
|
|
|
|
<div>数据更新时间:{{ item.dataUpdateTime }}</div>
|
2025-09-25 17:58:22 +08:00
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
2025-09-28 14:31:24 +08:00
|
|
|
|
<el-row>
|
|
|
|
|
|
<el-col v-for="(tempDataItem,tempDataIndex) in deviceIdTypeMsg[item.deviceId]" :key="tempDataIndex+'dbTempData'" :span="8">
|
2025-10-16 16:10:29 +08:00
|
|
|
|
<span class="pointer" @click="showChart(tempDataItem.pointName,item.deviceId)">
|
2025-09-28 14:31:24 +08:00
|
|
|
|
{{tempDataItem.name}}:{{item[tempDataItem.attr]}}<span v-html="tempDataItem.unit"></span>
|
|
|
|
|
|
</span>
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
</el-row>
|
2025-09-25 17:58:22 +08:00
|
|
|
|
</el-card>
|
2025-09-26 14:47:45 +08:00
|
|
|
|
<el-empty v-show="list.length<=0" :image-size="200"></el-empty>
|
2025-09-13 20:36:46 +08:00
|
|
|
|
<point-chart ref="pointChart" :site-id="siteId"/>
|
2025-08-15 14:13:54 +08:00
|
|
|
|
</div>
|
2025-06-22 17:22:40 +08:00
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
2025-09-13 20:36:46 +08:00
|
|
|
|
import pointChart from "./../PointChart.vue";
|
2025-06-30 17:32:04 +08:00
|
|
|
|
import getQuerySiteId from "@/mixins/ems/getQuerySiteId";
|
2025-08-15 14:13:54 +08:00
|
|
|
|
import { getAmmeterDataList } from "@/api/ems/dzjk";
|
2025-09-10 09:54:29 +08:00
|
|
|
|
import intervalUpdate from "@/mixins/ems/intervalUpdate";
|
2025-06-22 17:22:40 +08:00
|
|
|
|
export default {
|
2025-08-15 14:13:54 +08:00
|
|
|
|
name: "DzjkSbjkDb",
|
2025-09-10 09:54:29 +08:00
|
|
|
|
mixins: [getQuerySiteId,intervalUpdate],
|
2025-09-13 20:36:46 +08:00
|
|
|
|
components:{pointChart},
|
2025-06-22 17:22:40 +08:00
|
|
|
|
data() {
|
|
|
|
|
|
return {
|
2025-08-15 14:13:54 +08:00
|
|
|
|
loading: false,
|
2025-09-25 17:58:22 +08:00
|
|
|
|
list:[],
|
2025-09-28 14:31:24 +08:00
|
|
|
|
deviceIdTypeMsg:{
|
|
|
|
|
|
'LOAD':[
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'正向有功电能',
|
|
|
|
|
|
attr:'forwardActive',
|
|
|
|
|
|
pointName:'正向有功电能'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'反向有功电能',
|
|
|
|
|
|
attr:'reverseActive',
|
|
|
|
|
|
pointName:'反向有功电能'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'正向无功电能',
|
|
|
|
|
|
attr:'forwardReactive',
|
|
|
|
|
|
pointName:'正向无功电能'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'反向无功电能',
|
|
|
|
|
|
attr:'reverseReactive',
|
|
|
|
|
|
pointName:'反向无功电能'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'有功功率',
|
|
|
|
|
|
attr:'activePower',
|
|
|
|
|
|
pointName:'总有功功率'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'无功功率',
|
|
|
|
|
|
attr:'reactivePower',
|
|
|
|
|
|
pointName:'总无功功率'
|
|
|
|
|
|
}
|
|
|
|
|
|
],
|
|
|
|
|
|
'METE':[
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'正向有功电能',
|
|
|
|
|
|
attr:'forwardActive',
|
2025-09-28 16:18:34 +08:00
|
|
|
|
pointName:'正向有功电能'
|
2025-09-28 14:31:24 +08:00
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'反向有功电能',
|
|
|
|
|
|
attr:'reverseActive',
|
2025-09-28 16:18:34 +08:00
|
|
|
|
pointName:'反向有功电能'
|
2025-09-28 14:31:24 +08:00
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'正向无功电能',
|
|
|
|
|
|
attr:'forwardReactive',
|
2025-09-28 16:18:34 +08:00
|
|
|
|
pointName:'正向无功电能'
|
2025-09-28 14:31:24 +08:00
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'反向无功电能',
|
|
|
|
|
|
attr:'reverseReactive',
|
2025-09-28 16:18:34 +08:00
|
|
|
|
pointName:'反向无功电能'
|
2025-09-28 14:31:24 +08:00
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'有功功率',
|
|
|
|
|
|
attr:'activePower',
|
|
|
|
|
|
pointName:'总有功功率'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'无功功率',
|
|
|
|
|
|
attr:'reactivePower',
|
|
|
|
|
|
pointName:'总无功功率'
|
|
|
|
|
|
}
|
|
|
|
|
|
],
|
|
|
|
|
|
'METEGF':[
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'有功电能',
|
|
|
|
|
|
attr:'activeEnergy',
|
|
|
|
|
|
pointName:'有功电能'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'无功电能',
|
|
|
|
|
|
attr:'reactiveEnergy',
|
|
|
|
|
|
pointName:'无功电能'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'有功功率',
|
|
|
|
|
|
attr:'activePower',
|
|
|
|
|
|
pointName:'总有功功率'
|
|
|
|
|
|
},
|
|
|
|
|
|
{
|
|
|
|
|
|
name:'无功功率',
|
|
|
|
|
|
attr:'reactivePower',
|
|
|
|
|
|
pointName:'总无功功率'
|
|
|
|
|
|
}
|
|
|
|
|
|
]
|
|
|
|
|
|
}
|
2025-08-15 14:13:54 +08:00
|
|
|
|
};
|
2025-06-22 17:22:40 +08:00
|
|
|
|
},
|
2025-08-15 14:13:54 +08:00
|
|
|
|
methods: {
|
2025-10-16 16:10:29 +08:00
|
|
|
|
showChart(pointName,deviceId){
|
|
|
|
|
|
pointName && this.$refs.pointChart.showChart({pointName,deviceCategory:'AMMETER',deviceId})
|
2025-09-13 20:36:46 +08:00
|
|
|
|
},
|
2025-09-10 09:54:29 +08:00
|
|
|
|
updateData(){
|
2025-08-15 14:13:54 +08:00
|
|
|
|
this.loading = true;
|
|
|
|
|
|
getAmmeterDataList(this.siteId)
|
2025-09-10 09:54:29 +08:00
|
|
|
|
.then((response) => {
|
2025-09-26 14:47:45 +08:00
|
|
|
|
this.list = response?.data || []
|
2025-09-10 09:54:29 +08:00
|
|
|
|
})
|
|
|
|
|
|
.finally(() => {
|
|
|
|
|
|
this.loading = false;
|
|
|
|
|
|
});
|
|
|
|
|
|
},
|
|
|
|
|
|
init() {
|
|
|
|
|
|
this.updateData()
|
|
|
|
|
|
this.updateInterval(this.updateData)
|
2025-08-15 14:13:54 +08:00
|
|
|
|
},
|
2025-06-22 17:22:40 +08:00
|
|
|
|
},
|
2025-08-15 14:13:54 +08:00
|
|
|
|
mounted() {},
|
|
|
|
|
|
};
|
2025-06-22 17:22:40 +08:00
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
<style scoped lang="scss">
|
2025-09-22 17:57:30 +08:00
|
|
|
|
.sbjk-card-container {
|
2025-09-26 14:47:45 +08:00
|
|
|
|
&.list:not(:last-child){
|
|
|
|
|
|
margin-bottom: 25px;
|
|
|
|
|
|
}
|
2025-09-28 14:31:24 +08:00
|
|
|
|
.el-row{
|
|
|
|
|
|
background-color: #ffffff;
|
|
|
|
|
|
border:1px solid #eeeeee;
|
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
|
line-height: 16px;
|
|
|
|
|
|
color: #333333;
|
|
|
|
|
|
.el-col{
|
|
|
|
|
|
padding:12px 0;
|
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
position: relative;
|
|
|
|
|
|
}
|
|
|
|
|
|
.el-col{
|
|
|
|
|
|
border-bottom: 1px solid #eeeeee;
|
|
|
|
|
|
}
|
|
|
|
|
|
.el-col:not(:nth-child(3n)){
|
|
|
|
|
|
border-right: 1px solid #eeeeee;
|
2025-09-13 20:36:46 +08:00
|
|
|
|
}
|
2025-06-22 17:22:40 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
2025-09-17 14:52:08 +08:00
|
|
|
|
|
2025-06-22 17:22:40 +08:00
|
|
|
|
</style>
|