Browse Source

规则筛选-设备查询增加使用状态

develop
Mr.Wang 5 months ago
parent
commit
8db510f629
  1. 4
      zc-business/src/main/java/com/zc/business/service/impl/DcDeviceServiceImpl.java
  2. 5
      zc-business/src/main/java/com/zc/business/service/impl/DcEmergencyPlansServiceImpl.java

4
zc-business/src/main/java/com/zc/business/service/impl/DcDeviceServiceImpl.java

@ -427,7 +427,11 @@ public class DcDeviceServiceImpl extends ServiceImpl<DcDeviceMapper, DcDevice> i
String childType = String.valueOf(parameter.get("childType"));
String deviceState = String.valueOf(parameter.get("deviceState"));
String direction = String.valueOf(parameter.get("direction"));
Integer useState = Integer.parseInt(parameter.get("useState").toString());
DcDevice device = new DcDevice();
if (!Objects.equals(useState, "null")) {
device.setUseState(useState);
}
if (!Objects.equals(childType, "null")) {
device.setChildType(childType);
}

5
zc-business/src/main/java/com/zc/business/service/impl/DcEmergencyPlansServiceImpl.java

@ -494,6 +494,7 @@ public class DcEmergencyPlansServiceImpl implements DcEmergencyPlansService {
end.add(markArray[1]);
parameter.put("startStakeMark", start);
parameter.put("endStakeMark", end);
parameter.put("useState",1);
dcDevices = dcDeviceService.devicePileNumberQueryDevice(parameter);
Collections.sort(dcDevices, new Comparator<DcDevice>() {
@Override
@ -517,6 +518,7 @@ public class DcEmergencyPlansServiceImpl implements DcEmergencyPlansService {
end.add("154");
parameter.put("startStakeMark", start);
parameter.put("endStakeMark", end);
parameter.put("useState",1);
dcDevices = dcDeviceService.devicePileNumberQueryDevice(parameter);
Collections.sort(dcDevices, new Comparator<DcDevice>() {
@Override
@ -543,6 +545,7 @@ public class DcEmergencyPlansServiceImpl implements DcEmergencyPlansService {
end.add("154");
parameter.put("startStakeMark", start);
parameter.put("endStakeMark", end);
parameter.put("useState",1);
dcDevices = dcDeviceService.devicePileNumberQueryDevice(parameter);
Collections.sort(dcDevices, new Comparator<DcDevice>() {
@Override
@ -566,6 +569,7 @@ public class DcEmergencyPlansServiceImpl implements DcEmergencyPlansService {
end.add(markArray[1]);
parameter.put("startStakeMark", start);
parameter.put("endStakeMark", end);
parameter.put("useState",1);
dcDevices = dcDeviceService.devicePileNumberQueryDevice(parameter);
Collections.sort(dcDevices, new Comparator<DcDevice>() {
@Override
@ -594,6 +598,7 @@ public class DcEmergencyPlansServiceImpl implements DcEmergencyPlansService {
parameter.put("startStakeMark", start);
parameter.put("endStakeMark", end);
parameter.put("deviceType", dcExecuteAction.getDeviceType());
parameter.put("useState",1);
// 根据桩号范围,查询附近设备
dcDevices = dcDeviceService.devicePileNumberQueryDevice(parameter);
}

Loading…
Cancel
Save