diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/AppHydropowerDeviceVo.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/AppHydropowerDeviceVo.java index 604bd60..f650ba6 100644 --- a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/AppHydropowerDeviceVo.java +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/AppHydropowerDeviceVo.java @@ -28,4 +28,7 @@ public class AppHydropowerDeviceVo { @ApiModelProperty(value = "负荷单位") private String loadUnit; + + @ApiModelProperty(value = "排序") + private Integer ord; } diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/HydropowerUnitRealVo.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/HydropowerUnitRealVo.java index f4cf2f8..9784d6c 100644 --- a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/HydropowerUnitRealVo.java +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/main/vo/HydropowerUnitRealVo.java @@ -61,4 +61,7 @@ public class HydropowerUnitRealVo { @ApiModelProperty(value = "电流单位") private String currentUnit; + + @ApiModelProperty(value = "排序") + private Integer ord; } diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/ecology/service/impl/EcologyFlowStationServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/ecology/service/impl/EcologyFlowStationServiceImpl.java index bf9dbc4..8efdbc9 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/ecology/service/impl/EcologyFlowStationServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/ecology/service/impl/EcologyFlowStationServiceImpl.java @@ -179,7 +179,7 @@ public class EcologyFlowStationServiceImpl extends BaseServiceImpl station() { List stations = stationService.list(Wrappers.lambdaQuery() - .in(StationEntity::getCode,Arrays.asList("902400000054","902400052664"))); + .in(StationEntity::getCode,Arrays.asList("902400000054","902400052664","902400056791"))); if(CollectionUtil.isEmpty(stations)){ return new ArrayList<>(); } diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/main/service/impl/HydropowerServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/main/service/impl/HydropowerServiceImpl.java index 876c9e4..0c6eaf0 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/main/service/impl/HydropowerServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/main/service/impl/HydropowerServiceImpl.java @@ -153,6 +153,7 @@ public class HydropowerServiceImpl implements HydropowerService { HydropowerUnitRealVo real = new HydropowerUnitRealVo(); real.setDeptId(device.getCreateDept()); real.setDeviceCode(device.getEmCode()); + real.setOrd(device.getOrd()); real.setDeptName(device.getName()); real.setDeviceName(device.getName()); // 装机容量 @@ -1546,6 +1547,7 @@ public class HydropowerServiceImpl implements HydropowerService { // 设备 hydropower.setDevices(devices.stream().map(real->{ AppHydropowerDeviceVo device = new AppHydropowerDeviceVo(); + device.setOrd(real.getOrd()); device.setDeviceCode(real.getDeviceCode()); device.setDeviceName(real.getDeviceName()); device.setState(real.getState()); @@ -1553,7 +1555,7 @@ public class HydropowerServiceImpl implements HydropowerService { device.setCapacity(real.getInstalledCapacity()); device.setLoad(real.getActivePower()); return device; - }).collect(Collectors.toList())); + }).sorted(Comparator.comparing(AppHydropowerDeviceVo::getOrd)).collect(Collectors.toList())); hydropower.setLoadUnit(hydropower.getDevices().get(0).getLoadUnit()); } return hydropower;