diff --git a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/monitor/impl/MonitorServiceImpl.java b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/monitor/impl/MonitorServiceImpl.java index 23c60be..34ecc71 100644 --- a/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/monitor/impl/MonitorServiceImpl.java +++ b/hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/monitor/impl/MonitorServiceImpl.java @@ -342,10 +342,10 @@ public class MonitorServiceImpl implements MonitorService { }); // 设备状态 this.getDeviceParam(devices, deviceClassifyMap, deviceList); - // 运行设备状态设置 - this.deviceState(deviceList); // 设置站点状态:数据中断 this.setStationStatus(aborts,station,key,deviceList); + // 运行设备状态设置 + this.deviceState(deviceList,station.getStatus()); // 铃铛 this.stationBell(station,bells); station.setDeviceList(deviceList.stream().sorted(Comparator.comparing((RealDeviceVo::getDeviceName))).collect(Collectors.toList())); @@ -420,14 +420,15 @@ public class MonitorServiceImpl implements MonitorService { * 设备状态 * @param deviceList */ - private void deviceState(List deviceList) { + private void deviceState(List deviceList,Integer status) { deviceList.forEach(device->{ // 设备属性列表 List attbts = device.getAttbtList(); - if(CollectionUtil.isEmpty(attbts)){ + if(CollectionUtil.isEmpty(attbts) || status == 1){ device.setState(-1); return; } + // 功率属性记录 List powers = attbts.stream().filter(att-> HomePageConstant.powerList.contains(att.getName())).collect(Collectors.toList()); if(CollectionUtil.isEmpty(powers)){