diff --git a/src/subpackage/device/pages/switch_manage/switch_manage.vue b/src/subpackage/device/pages/switch_manage/switch_manage.vue index 54b686a..0a8efda 100644 --- a/src/subpackage/device/pages/switch_manage/switch_manage.vue +++ b/src/subpackage/device/pages/switch_manage/switch_manage.vue @@ -3,7 +3,7 @@ {{pageInfo.name || '-'}} *长开表示不再被系统智能控制,只有手动关闭后才会被智能控制。请谨慎操作。 - 现场电源断开,则无法获取到开关状态;状态是通过硬件发送通知给服务器,则状态获取可能存在延时。 + 现场电源断开,则无法获取到开关状态;状态是通过硬件发送通知给服务器,则状态获取可能存在延时。 @@ -23,8 +23,11 @@ - - 当前开关状态:{{ (e.extension&&e.extension.hardware_status_info&&e.extension.hardware_status_info.switch_status) || '-' }} + + 当前开关状态:{{ e.extension.hardware_status_info.switch_status || '-' }} @@ -103,7 +106,13 @@ export default { let widthViewArr = ["照明管理","水阀管理","风扇管理"] return (widthViewArr.indexOf(this.pageInfo.name)>=0)?'710rpx':''; } - } + }, + isShowSwitchStatusTip(){ + let { deviceList, pageInfo } = this; + let _typeBol = ['Light', 'Air'].includes(pageInfo.hardware_type); + let _deviceStatusBol = deviceList.some(e=>!!e?.extension?.hardware_status_info?.switch_status); + return _typeBol&&_deviceStatusBol; + } }, watch: { curStoreInfo(newVal, oldVal){