diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/DeviceControlDialog.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/DeviceControlDialog.vue index 97154b00..f8d6adb6 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/DeviceControlDialog.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/DeviceControlDialog.vue @@ -129,10 +129,22 @@ let text = e ==true? "打开" : "关闭"; this.$modal.confirm('确认要"' + text + '"门锁').then(() => { return request({ - url: `/business/device/functions/${this.dialogData.iotDeviceId}/SL`, + url: `/business/device/batchFunctions`, method: "post", data: { - switch:e?1:0 + devices: [{ + iotDeviceId: this.dialogData.iotDeviceId, + id: this.dialogData.id, + deviceType: 17 + }], + functions: [ + { + functionId: "SL", + params: { + switch:e?1:0 + } + } + ], }, }) .then((result)=>{ @@ -169,9 +181,21 @@ // return this.lightningReset =e // } return request({ - url: `/business/device/functions/${this.dialogData.iotDeviceId}/TL`, + url: `/business/device/batchFunctions`, method: "post", - data: {}, + data: { + devices: [{ + iotDeviceId: this.dialogData.iotDeviceId, + id: this.dialogData.id, + deviceType: 17 + }], + functions: [ + { + functionId: "TL", + params: {} + } + ], + }, }) .then((result)=>{ if (result.code != 200) { @@ -202,9 +226,21 @@ return this.recloserReset =e } return request({ - url: `/business/device/functions/${this.dialogData.iotDeviceId}/SR`, + url: `/business/device/batchFunctions`, method: "post", - data: {}, + data: { + devices: [{ + iotDeviceId: this.dialogData.iotDeviceId, + id: this.dialogData.id, + deviceType: 17 + }], + functions: [ + { + functionId: "SR", + params: {} + } + ], + }, }) .then((result)=>{ if (result.code != 200) { @@ -235,9 +271,21 @@ return this.reclosing =e } return request({ - url: `/business/device/functions/${this.dialogData.iotDeviceId}/RS`, + url: `/business/device/batchFunctions`, method: "post", - data: {}, + data: { + devices: [{ + iotDeviceId: this.dialogData.iotDeviceId, + id: this.dialogData.id, + deviceType: 17 + }], + functions: [ + { + functionId: "RS", + params: {} + } + ], + }, }) .then((result)=>{ if (result.code != 200) { diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/DeviceParams.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/DeviceParams.vue index 43d917ae..a42f60bd 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/DeviceParams.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/IntegratedCabinet/components/DeviceParams.vue @@ -102,7 +102,7 @@ if (result.code != 200) return Message.error("操作失败"); result.data.forEach(item => { if (item.propertyName) { - if (item.propertyName === "温湿度状态-湿度" || item.propertyName === "温湿度状态-温度" + if (item.propertyName === "温湿度状态-湿度" || item.propertyName === "温湿度状态-温度"|| item.propertyName === "频闪灯开关" ||item.propertyName === "环境温度"||item.propertyName === "环境光度"||item.propertyName === "环境湿度"||item.propertyName === "系统状态-环境(温湿度等)") { // 如果是环境相关的数据,添加到environment集合 envDevs.push({