|
|
@@ -93,7 +93,7 @@
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <view class="" v-if="side_type == 13">
|
|
|
+ <view class="" v-if="side_type == 13 || side_type=='xph'">
|
|
|
<image src="http://www.hnyfwlw.com:8006/bigdata_app/image/prevention/6.png" mode=""
|
|
|
class="prevents_item_img"></image>
|
|
|
<view class="prevents_item_top">
|
|
|
@@ -161,6 +161,12 @@
|
|
|
list: [],
|
|
|
pageIndex: 1,
|
|
|
tf: false,
|
|
|
+ }, {
|
|
|
+ name: '水肥一体化',
|
|
|
+ type: 'xph', //5 环境监测 15 管式墒情
|
|
|
+ list: [],
|
|
|
+ pageIndex: 1,
|
|
|
+ tf: false,
|
|
|
}],
|
|
|
active: 0, //tab选中的下标
|
|
|
side_type: 17, //当前选中的设备类型
|
|
|
@@ -173,6 +179,20 @@
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
+ async xphlist() {
|
|
|
+ this.loadingtf = true
|
|
|
+ const res = await this.$myRequest({
|
|
|
+ url: '/api/api_gateway?method=xphsp.views.all_devices',
|
|
|
+ data: {
|
|
|
+ page: this.page,
|
|
|
+ page_size: "10",
|
|
|
+ device_id: this.imports,
|
|
|
+ }
|
|
|
+ })
|
|
|
+ this.loadingtf = false
|
|
|
+ this.eqlistdata = this.eqlistdata.concat(res.data)
|
|
|
+ console.log(this.eqlistdata)
|
|
|
+ },
|
|
|
async eqlist() { //设备列表 水肥一体化 L
|
|
|
this.loadingtf = true
|
|
|
const res = await this.$myRequest({
|
|
|
@@ -235,6 +255,10 @@
|
|
|
uni.navigateTo({
|
|
|
url: "../waterandfer/datails?shebei=" + JSON.stringify(data)
|
|
|
})
|
|
|
+ } else if(this.side_type == 'xph') {
|
|
|
+ uni.navigateTo({
|
|
|
+ url: "../waterandfernew/details?shebei=" + JSON.stringify(data)
|
|
|
+ })
|
|
|
}
|
|
|
},
|
|
|
top() {
|
|
|
@@ -256,6 +280,8 @@
|
|
|
this.tubulareqlist()
|
|
|
} else if (this.side_type == 13) {
|
|
|
this.sfeqlist()
|
|
|
+ } else if (this.side_type == 'xph') {
|
|
|
+ this.xphlist()
|
|
|
}
|
|
|
}, 1000)()
|
|
|
},
|
|
|
@@ -272,6 +298,9 @@
|
|
|
} else if (type == 13) {
|
|
|
this.eqlistdata = []
|
|
|
this.sfeqlist()
|
|
|
+ } else if (type == 'xph') {
|
|
|
+ this.eqlistdata = []
|
|
|
+ this.xphlist()
|
|
|
}
|
|
|
},
|
|
|
timezhuan(time) {
|
|
|
@@ -457,6 +486,9 @@
|
|
|
case 195:
|
|
|
this.equipArr[2].tf = true
|
|
|
break;
|
|
|
+ case 288:
|
|
|
+ this.equipArr[3].tf = true
|
|
|
+ break;
|
|
|
}
|
|
|
}
|
|
|
for (var i = 0; i < this.equipArr.length; i++) {
|
|
|
@@ -465,8 +497,10 @@
|
|
|
this.tubulareqlist();
|
|
|
} else if (i == 1) {
|
|
|
this.eqlist();
|
|
|
- } else {
|
|
|
+ } else if (i == 2) {
|
|
|
this.sfeqlist();
|
|
|
+ } else {
|
|
|
+ this.xphlist();
|
|
|
}
|
|
|
this.active = i
|
|
|
this.side_type = this.equipArr[i].type
|
|
|
@@ -485,6 +519,8 @@
|
|
|
this.tubulareqlist()
|
|
|
} else if (this.side_type == 13) {
|
|
|
this.sfeqlist()
|
|
|
+ } else if (this.side_type == 'xph') {
|
|
|
+ this.xphlist()
|
|
|
}
|
|
|
},
|
|
|
onPageScroll(e) { //nvue暂不支持滚动监听,可用bindingx代替
|
|
|
@@ -558,7 +594,7 @@
|
|
|
top: 170px;
|
|
|
display: flex;
|
|
|
justify-content: space-around;
|
|
|
- font-size: 30rpx;
|
|
|
+ font-size: 24rpx;
|
|
|
line-height: 80rpx;
|
|
|
background-color: #FFFFFF;
|
|
|
width: 100%;
|