Compare commits

...

3 Commits

Author SHA1 Message Date
xiaomeng 38dd0b3a3c Merge pull request 'pc-master' (#139) from pc-master into portal
Reviewed-on: #139
2024-04-02 07:25:50 +00:00
孙萌 d30b533128 1 2024-04-02 15:24:31 +08:00
孙萌 d60d3b2521 1 2024-04-02 15:15:13 +08:00
2 changed files with 23 additions and 10 deletions

View File

@ -415,10 +415,18 @@ export default {
return
}
this.$router.push({ path: `/control?change=${item.index}` })
} else if (item.deviceName == 1 && this.routerNow != 'irrigateSet') {
this.$store.state.equipmentIndex = item.index
this.routerIndex = item.index
this.$router.push({ path: `/irrigateSet?change=${item.index}` })
} else if (item.deviceName == 1 ) {
if(this.routerNow == 'irrigateSet'){
this.$store.state.equipmentIndex = item.index
this.routerIndex = item.index
}else{
this.$store.state.equipmentIndex = item.index
this.routerIndex = item.index
this.$router.push({ path: `/irrigateSet?change=${item.index}` })
}
} else if (item.deviceName == 30) {
this.$message('气象站无该页面');
}

View File

@ -141,14 +141,13 @@ export default {
'active'(newVal, oldVal) {
this.getSensorType()
},
'$store.state.equipmentIndex'(newVal, oldVal) {
this.dataInit();
},
},
mounted() {
this.loading = this.$loading({
lock: true,
text: '加载中',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
this.dataInit()
//input
let inputList = document.querySelectorAll('input');
@ -409,6 +408,12 @@ return num
deviceId: store.equipmentList[store.equipmentIndex - 1].deviceId,
};
this.loading = this.$loading({
lock: true,
text: '加载中',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
this.api.getReadControlSensorChannel(data).then((res) => {
this.loading.close()
if (res.data.code == 200) {