Browse Source

#云服务去除数据中断校验

zhongwei
yang_shj 11 months ago
parent
commit
cf74244a66
  1. 6
      hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/monitor/impl/MonitorServiceImpl.java

6
hzims-service/hzims-scheduled/src/main/java/com/hnac/hzims/scheduled/service/operation/monitor/impl/MonitorServiceImpl.java

@ -345,7 +345,7 @@ public class MonitorServiceImpl implements MonitorService {
// 设置站点状态:数据中断 // 设置站点状态:数据中断
this.setStationStatus(aborts,station,key,deviceList); this.setStationStatus(aborts,station,key,deviceList);
// 运行设备状态设置 // 运行设备状态设置
this.deviceState(deviceList,station.getStatus()); this.deviceState(deviceList);
// 铃铛 // 铃铛
this.stationBell(station,bells); this.stationBell(station,bells);
station.setDeviceList(deviceList.stream().sorted(Comparator.comparing((RealDeviceVo::getDeviceName))).collect(Collectors.toList())); station.setDeviceList(deviceList.stream().sorted(Comparator.comparing((RealDeviceVo::getDeviceName))).collect(Collectors.toList()));
@ -420,11 +420,11 @@ public class MonitorServiceImpl implements MonitorService {
* 设备状态 * 设备状态
* @param deviceList * @param deviceList
*/ */
private void deviceState(List<RealDeviceVo> deviceList,Integer status) { private void deviceState(List<RealDeviceVo> deviceList) {
deviceList.forEach(device->{ deviceList.forEach(device->{
// 设备属性列表 // 设备属性列表
List<RealAttributeVo> attbts = device.getAttbtList(); List<RealAttributeVo> attbts = device.getAttbtList();
if(CollectionUtil.isEmpty(attbts) || status == 1){ if(CollectionUtil.isEmpty(attbts)){
device.setState(-1); device.setState(-1);
return; return;
} }

Loading…
Cancel
Save