Commit 4a429fc3 authored by zhangsen's avatar zhangsen

bug修改

parent 362b8301
......@@ -502,8 +502,18 @@ public class BigScreenAnalyseController extends BaseController {
List<Map<String, Object>> pointNameList = idxBizFanHealthIndexMapper.getPointNameListBySumSystem(stationBasic.getFanGatewayId(), subSystem);
pointNameList.forEach(item -> {
String warningName = equipmentHealthIndexMap.getOrDefault(item.get("pointName"), "安全");
int sort = 4;
item.put("warningName", warningName);
if ("注意".equals(warningName)) {
sort = 1;
} else if ("警告".equals(warningName)) {
sort = 2;
} else if ("危险".equals(warningName)) {
sort = 3;
}
item.put("sort", sort);
});
pointNameList.sort(Comparator.comparing(o -> o.get("sort").toString()));
Page<Map<String, Object>> mapPage = new Page<>();
mapPage.setSize(pointNameList.size());
mapPage.setTotal(pointNameList.size());
......@@ -593,8 +603,19 @@ public class BigScreenAnalyseController extends BaseController {
List<Map<String, Object>> pointNameList = idxBizFanHealthIndexMapper.getPvPointNameListBySumSystem(stationBasic.getFanGatewayId(), equipmentName);
pointNameList.forEach(item -> {
String equipmentHealthScore = equipmentHealthIndexMap.getOrDefault(item.get("pointName"), "安全");
int sort = 4;
item.put("warningName", equipmentHealthScore);
if ("注意".equals(equipmentHealthScore)) {
sort = 1;
} else if ("警告".equals(equipmentHealthScore)) {
sort = 2;
} else if ("危险".equals(equipmentHealthScore)) {
sort = 3;
}
item.put("sort", sort);
item.put("warningName", equipmentHealthScore);
});
pointNameList.sort(Comparator.comparing(o -> o.get("sort").toString()));
Page<Map<String, Object>> mapPage = new Page<>();
mapPage.setSize(pointNameList.size());
mapPage.setTotal(pointNameList.size());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment