|
@@ -34,48 +34,44 @@
|
|
<view>
|
|
<view>
|
|
|
|
|
|
|
|
|
|
- <view class="item" @click="orderByShow=true">
|
|
|
|
- <view class="title">
|
|
|
|
- 三项电流详情(A)
|
|
|
|
- </view>
|
|
|
|
- <view>
|
|
|
|
- {{orderByIndex.label}}
|
|
|
|
- <u-icon name="arrow-down"></u-icon>
|
|
|
|
- </view>
|
|
|
|
|
|
+ <view class="item">
|
|
|
|
+ <view class="title">
|
|
|
|
+ 查询数量
|
|
|
|
+ </view>
|
|
|
|
+ <view >
|
|
|
|
+
|
|
|
|
+ <span v-for="(item,i) in queryNumSz"
|
|
|
|
+ @click="queryNum=item,getAlarmRecordTPUDetails(id)"
|
|
|
|
+ :class="{
|
|
|
|
+ queryNum:1,
|
|
|
|
+ queryNumIndex:item==queryNum
|
|
|
|
+ }">
|
|
|
|
+ {{item}}
|
|
|
|
+ </span>
|
|
|
|
+
|
|
|
|
+ </view>
|
|
</view>
|
|
</view>
|
|
- <view class="item">
|
|
|
|
- <table class="border-table ">
|
|
|
|
- <tr>
|
|
|
|
- <td>设备名称</td>
|
|
|
|
-
|
|
|
|
- <td :class="{
|
|
|
|
- orderByIndex:(orderByIndex.value==0||orderByIndex.value==2)
|
|
|
|
- }">A相</td>
|
|
|
|
- <td :class="{
|
|
|
|
- orderByIndex:(orderByIndex.value==0||orderByIndex.value==1)
|
|
|
|
- }">B相</td>
|
|
|
|
- <td :class="{
|
|
|
|
- orderByIndex:(orderByIndex.value==1||orderByIndex.value==2)
|
|
|
|
- }">C相</td>
|
|
|
|
-
|
|
|
|
- </tr>
|
|
|
|
- <tr v-for="(item,i) in childDcMap" :key="i" :class="{
|
|
|
|
- childDcMap:i==0
|
|
|
|
- }">
|
|
|
|
- <td >{{item.meterName}}</td>
|
|
|
|
- <td :class="{
|
|
|
|
- orderByIndex:(orderByIndex.value==0||orderByIndex.value==2)
|
|
|
|
- }">{{item.dcAA}}</td>
|
|
|
|
- <td :class="{
|
|
|
|
- orderByIndex:(orderByIndex.value==0||orderByIndex.value==1)
|
|
|
|
- }">{{item.dcBa}}</td>
|
|
|
|
- <td :class="{
|
|
|
|
- orderByIndex:(orderByIndex.value==1||orderByIndex.value==2)
|
|
|
|
- }">{{item.dcCa}}</td>
|
|
|
|
-
|
|
|
|
- </tr>
|
|
|
|
-
|
|
|
|
- </table>
|
|
|
|
|
|
+ <view class="item">
|
|
|
|
+ <table class="border-table ">
|
|
|
|
+ <tr>
|
|
|
|
+ <td>设备名称</td>
|
|
|
|
+
|
|
|
|
+ <td v-for="(item,i) in keySz" :key="i" :class="'keySz'+i">
|
|
|
|
+ {{item.name}}
|
|
|
|
+ </td>
|
|
|
|
+
|
|
|
|
+ </tr>
|
|
|
|
+ <tr v-for="(item1,j) in childDcMap" :key="i" :class="{
|
|
|
|
+ childDcMap:j==0
|
|
|
|
+ }">
|
|
|
|
+ <td >{{item1.meterName}}</td>
|
|
|
|
+ <td v-for="(item,i) in keySz" :key="i" :class="'keySz'+i">
|
|
|
|
+ {{item1[item.value]}}
|
|
|
|
+ </td>
|
|
|
|
+
|
|
|
|
+ </tr>
|
|
|
|
+
|
|
|
|
+ </table>
|
|
</view>
|
|
</view>
|
|
|
|
|
|
</view>
|
|
</view>
|
|
@@ -163,7 +159,10 @@
|
|
}, {
|
|
}, {
|
|
value: "2",
|
|
value: "2",
|
|
label: "按C与A的差值排序"
|
|
label: "按C与A的差值排序"
|
|
- }, ]
|
|
|
|
|
|
+ }, ],
|
|
|
|
+ queryNum:5,
|
|
|
|
+ queryNumSz:[5,8,10,15],
|
|
|
|
+ keySz:[],
|
|
}
|
|
}
|
|
},
|
|
},
|
|
onLoad(op) {
|
|
onLoad(op) {
|
|
@@ -180,27 +179,7 @@
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
childDcMapsort() {
|
|
childDcMapsort() {
|
|
- var value = this.orderByIndex.value
|
|
|
|
- var childDcMap = []
|
|
|
|
- var id = this.remoteMonitorMeter.id;
|
|
|
|
|
|
|
|
- this.childDcMap.sort((it1, it2) => {
|
|
|
|
- if (it1.meterId == id) {
|
|
|
|
-
|
|
|
|
- return -1
|
|
|
|
- }
|
|
|
|
- if (it2.meterId == id) {
|
|
|
|
-
|
|
|
|
- return 1
|
|
|
|
- }
|
|
|
|
- if (value == '0') {
|
|
|
|
- return it1.abDifference < it2.abDifference ? 1 : -1
|
|
|
|
- } else if (value == '1') {
|
|
|
|
- return it1.bcDifference < it2.bcDifference ? 1 : -1
|
|
|
|
- } else if (value == '2') {
|
|
|
|
- return it1.acDifference < it2.acDifference ? 1 : -1
|
|
|
|
- }
|
|
|
|
- })
|
|
|
|
},
|
|
},
|
|
orderconfirm(e) {
|
|
orderconfirm(e) {
|
|
console.log(e)
|
|
console.log(e)
|
|
@@ -220,7 +199,16 @@
|
|
this.childDcMap = response.data.childDcMap;
|
|
this.childDcMap = response.data.childDcMap;
|
|
this.companyInfo = response.data.companyInfo;
|
|
this.companyInfo = response.data.companyInfo;
|
|
this.remoteMonitorMeter = response.data.meter;
|
|
this.remoteMonitorMeter = response.data.meter;
|
|
-
|
|
|
|
|
|
+ var sz=response.data.sort;
|
|
|
|
+ this.keySz=[]
|
|
|
|
+ for(var i in sz){
|
|
|
|
+
|
|
|
|
+ var obj=sz[i].split(',')
|
|
|
|
+ this.keySz.push({
|
|
|
|
+ name:obj[0],
|
|
|
|
+ value:obj[1]
|
|
|
|
+ })
|
|
|
|
+ }
|
|
this.childDcMapsort()
|
|
this.childDcMapsort()
|
|
}).catch(error => {
|
|
}).catch(error => {
|
|
uni.showToast({
|
|
uni.showToast({
|
|
@@ -230,29 +218,7 @@
|
|
})
|
|
})
|
|
},
|
|
},
|
|
getAlarmRecordDetails(id) {
|
|
getAlarmRecordDetails(id) {
|
|
- uni.showLoading({
|
|
|
|
- title: "加载中",
|
|
|
|
- mask: true,
|
|
|
|
- })
|
|
|
|
- API.alarmRecordDetails(id).then((response) => {
|
|
|
|
- uni.hideLoading();
|
|
|
|
- this.companyInfo = response.data.companyInfo;
|
|
|
|
- this.remoteMonitorMeter = response.data.meter;
|
|
|
|
-
|
|
|
|
- this.remoteMonitorRecord = response.data.remoteMonitorRecord;
|
|
|
|
- this.alarmRecord = response.data.alarmRecord;
|
|
|
|
- this.alarmConfig = response.data.alarmConfig;
|
|
|
|
- if (this.alarmConfig.code == 'TPU') {
|
|
|
|
- // this.childDcMap=response.data.childDcMap;
|
|
|
|
- this.getAlarmRecordTPUDetails(id, this.remoteMonitorMeter.id)
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- }).catch(error => {
|
|
|
|
- uni.showToast({
|
|
|
|
- title: error,
|
|
|
|
- icon: "none"
|
|
|
|
- })
|
|
|
|
- })
|
|
|
|
|
|
+
|
|
},
|
|
},
|
|
getLineCharts() {
|
|
getLineCharts() {
|
|
if (!this.myLineChart) {
|
|
if (!this.myLineChart) {
|
|
@@ -523,13 +489,21 @@
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
- .orderByIndex {
|
|
|
|
- font-weight: bold;
|
|
|
|
- background-color: #CDDC39;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .childDcMap td {
|
|
|
|
- background-color: #1677FF !important;
|
|
|
|
- color: #fff !important;
|
|
|
|
|
|
+ .keySz0,.keySz1{
|
|
|
|
+ font-weight: bold;
|
|
|
|
+ background-color: #f8f0a6;
|
|
|
|
+ }
|
|
|
|
+ .childDcMap td{
|
|
|
|
+ background-color: #1677FF !important ;
|
|
|
|
+ color:#fff !important ;
|
|
|
|
+ }
|
|
|
|
+ .queryNum{
|
|
|
|
+ border: 1px solid #9E9E9E;
|
|
|
|
+ padding: 4rpx 16rpx;
|
|
|
|
+ margin: 8rpx ;
|
|
|
|
+ }
|
|
|
|
+ .queryNumIndex{
|
|
|
|
+ color: #fff;
|
|
|
|
+ background: #1677FF;
|
|
}
|
|
}
|
|
</style>
|
|
</style>
|