Commit 26be8ab6 authored by zhangsen's avatar zhangsen

排序问题修改

parent e503abdf
...@@ -256,7 +256,7 @@ public class BigScreenAnalyseController extends BaseController { ...@@ -256,7 +256,7 @@ public class BigScreenAnalyseController extends BaseController {
HashMap<String, Integer> wxMap = new HashMap<>(); HashMap<String, Integer> wxMap = new HashMap<>();
HashMap<String, Integer> zyMap = new HashMap<>(); HashMap<String, Integer> zyMap = new HashMap<>();
HashMap<String, Integer> jgMap = new HashMap<>(); HashMap<String, Integer> jgMap = new HashMap<>();
Set<String> list = new HashSet<>(); LinkedHashSet<String> list = new LinkedHashSet<>();
allEquipAlarmInfo.forEach(item -> { allEquipAlarmInfo.forEach(item -> {
if ("危险".equals(item.get("warningName"))) { if ("危险".equals(item.get("warningName"))) {
wxMap.put(item.get("station").toString(), Integer.parseInt(item.get("num").toString())); wxMap.put(item.get("station").toString(), Integer.parseInt(item.get("num").toString()));
...@@ -549,13 +549,13 @@ public class BigScreenAnalyseController extends BaseController { ...@@ -549,13 +549,13 @@ public class BigScreenAnalyseController extends BaseController {
if (100.0 == equipmentHealthScore) { if (100.0 == equipmentHealthScore) {
item.put("warningName", "安全"); item.put("warningName", "安全");
} else { } else {
LambdaQueryWrapper<IdxBizFanHealthLevel> query = new LambdaQueryWrapper<>(); LambdaQueryWrapper<IdxBizPvHealthLevel> query = new LambdaQueryWrapper<>();
query.eq(IdxBizFanHealthLevel::getAnalysisObjType, "设备"); query.eq(IdxBizPvHealthLevel::getAnalysisObjType, "设备");
query.eq(IdxBizFanHealthLevel::getStatus, stationBasic.getStationName()); query.eq(IdxBizPvHealthLevel::getStatus, item.get("station").toString());
query.lt(IdxBizFanHealthLevel::getGroupLowerLimit, equipmentHealthScore); query.lt(IdxBizPvHealthLevel::getGroupLowerLimit, equipmentHealthScore);
query.ge(IdxBizFanHealthLevel::getGroupUpperLimit, equipmentHealthScore); query.ge(IdxBizPvHealthLevel::getGroupUpperLimit, equipmentHealthScore);
IdxBizFanHealthLevel idxBizFanHealthLevel = idxBizFanHealthLevelMapper.selectOne(query); IdxBizPvHealthLevel idxBizPvHealthLevel = idxBizPvHealthLevelMapper.selectOne(query);
item.put("warningName", idxBizFanHealthLevel.getHealthLevel()); item.put("warningName", idxBizPvHealthLevel.getHealthLevel());
} }
item.put("healthIndex", equipmentHealthScore); item.put("healthIndex", equipmentHealthScore);
String subarray = CharSequenceUtil.replace(item.get("subarray").toString(), "#", ""); String subarray = CharSequenceUtil.replace(item.get("subarray").toString(), "#", "");
......
...@@ -211,7 +211,7 @@ ...@@ -211,7 +211,7 @@
WARNING_NAME WARNING_NAME
) a ) a
ORDER BY ORDER BY
a.allNum desc a.allNum ASC
</select> </select>
...@@ -291,10 +291,18 @@ ...@@ -291,10 +291,18 @@
<select id="getAllEquipAlarmInfoAnalysisByStationType" resultType="java.util.Map"> <select id="getAllEquipAlarmInfoAnalysisByStationType" resultType="java.util.Map">
SELECT SELECT
<!-- ( SELECT POINT_NAME FROM ${tableName2} WHERE GATEWAY_ID = a.GATEWAY_ID AND INDEX_ADDRESS = a.INDEX_ADDRESS ) AS pointName,-->
concat(#{stationType}, '-', a.POINT_NAME) as pointName, concat(#{stationType}, '-', a.POINT_NAME) as pointName,
a.WARNING_NAME as warningName, a.WARNING_NAME as warningName,
count(1) as num count(1) as num,
(select count(1) from ${tableName} as tb
<where>
tb.DISPOSOTION_STATE = '未处置'
and tb.POINT_NAME = a.POINT_NAME
<if test="areaCode != null and areaCode != ''">
and tb.ARAE like concat('%', #{areaCode}, '%')
</if>
</where>
) AS totalNum
FROM FROM
${tableName} a ${tableName} a
<where> <where>
...@@ -307,7 +315,7 @@ ...@@ -307,7 +315,7 @@
warningName warningName
having pointName IS NOT NULL having pointName IS NOT NULL
AND pointName != '' AND pointName != ''
order by num asc order by totalNum asc
</select> </select>
<select id="getAllEquipAlarmInfoAnalysisByArea" resultType="java.util.Map"> <select id="getAllEquipAlarmInfoAnalysisByArea" resultType="java.util.Map">
...@@ -507,7 +515,8 @@ ...@@ -507,7 +515,8 @@
<select id="getPvInfoByPage" resultType="java.util.Map"> <select id="getPvInfoByPage" resultType="java.util.Map">
SELECT SELECT
SUBARRAY as subarray SUBARRAY as subarray,
STATION AS station
FROM FROM
idx_biz_pv_point_process_variable_classification idx_biz_pv_point_process_variable_classification
<where> <where>
......
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