Commit e17cd777 authored by chenzhao's avatar chenzhao

修改接口数据排序

parent c052b9b1
......@@ -278,12 +278,25 @@ public class IdxBizFanHealthIndexController extends BaseController {
public ResponseModel<List<Map<String,Object>>> getFanEquipStatusByStation(String STATION) {
Map<String, Object> map = idxBizFanHealthIndexServiceImpl.getFanEquipStatusByStation(STATION);
List<Map<String,Object>> maps = new ArrayList<>();
for (String s : map.keySet()) {
Map<String,Object> result = new HashMap<>();
result.put("name",s);
result.put("value",map.get(s));
maps.add(result);
}
Map<String,Object> anquan = new HashMap<>();
anquan.put("name","安全");
anquan.put("value",map.get("安全"));
maps.add(anquan);
Map<String,Object> zhuyi = new HashMap<>();
zhuyi.put("name","注意");
zhuyi.put("value",map.get("注意"));
maps.add(zhuyi);
Map<String,Object> jinggao = new HashMap<>();
jinggao.put("name","警告");
jinggao.put("value",map.get("警告"));
maps.add(jinggao);
Map<String,Object> weixian = new HashMap<>();
weixian.put("name","危险");
weixian.put("value",map.get("危险"));
maps.add(weixian);
return ResponseHelper.buildResponse(maps);
}
......
......@@ -1196,9 +1196,7 @@
GROUP BY
STATION,
HEALTH_LEVEL
) a <where>
</where>
) a
</select>
</mapper>
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