Commit 005d94f9 authored by chenzhao's avatar chenzhao

修改接口

parent 57b2f3a7
...@@ -23,10 +23,7 @@ import org.typroject.tyboot.core.restful.utils.ResponseModel; ...@@ -23,10 +23,7 @@ import org.typroject.tyboot.core.restful.utils.ResponseModel;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import javax.ws.rs.POST; import javax.ws.rs.POST;
import java.util.ArrayList; import java.util.*;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/** /**
* *
...@@ -261,6 +258,10 @@ public class IdxBizFanHealthIndexController extends BaseController { ...@@ -261,6 +258,10 @@ public class IdxBizFanHealthIndexController extends BaseController {
Map<String,Object> result = new HashMap<>(); Map<String,Object> result = new HashMap<>();
List<Object> seriesData = new ArrayList<>(); List<Object> seriesData = new ArrayList<>();
List<Object> axisData = new ArrayList<>(); List<Object> axisData = new ArrayList<>();
Collections.reverse(seriesData);
Collections.reverse(axisData);
for (Map<String, Object> map : maps) { for (Map<String, Object> map : maps) {
seriesData.add(map.get("value")); seriesData.add(map.get("value"));
axisData.add(map.get("REC_DATE")); axisData.add(map.get("REC_DATE"));
......
...@@ -15,10 +15,7 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper; ...@@ -15,10 +15,7 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel; import org.typroject.tyboot.core.restful.utils.ResponseModel;
import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletRequest;
import java.util.ArrayList; import java.util.*;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/** /**
* *
...@@ -194,13 +191,16 @@ public class IdxBizPvHealthIndexController extends BaseController { ...@@ -194,13 +191,16 @@ public class IdxBizPvHealthIndexController extends BaseController {
} }
@TycloudOperation(ApiLevel = UserType.AGENCY,needAuth = false) @TycloudOperation(ApiLevel = UserType.AGENCY,needAuth = false)
@ApiOperation(httpMethod = "GET",value = "预警监测设备级统计", notes = "预警监测设备级统计") @ApiOperation(httpMethod = "GET",value = "预警监测设备级统计", notes = "预警监测设备级统计")
@GetMapping(value = "/queryForPointNum") @GetMapping(value = "/selectPointByANALYSISTYPE")
public ResponseModel<Map<String,Object>> selectPointByANALYSISTYPE(@RequestParam(required = false) String STATION, @RequestParam(required = false)String HEALTHLEVEL,@RequestParam(required = false) String EQUIPMENTNAME,@RequestParam(required = false)String POINTNAME,@RequestParam(required = false)String SUBARRAY,@RequestParam(required = false)String startTime,@RequestParam(required = false) String endTime) { public ResponseModel<Map<String,Object>> selectPointByANALYSISTYPE(@RequestParam(required = false) String STATION, @RequestParam(required = false)String HEALTHLEVEL,@RequestParam(required = false) String EQUIPMENTNAME,@RequestParam(required = false)String POINTNAME,@RequestParam(required = false)String SUBARRAY,@RequestParam(required = false)String startTime,@RequestParam(required = false) String endTime) {
List<Map<String, Object>> maps = idxBizPvHealthIndexServiceImpl.selectPointByANALYSISTYPE(STATION, HEALTHLEVEL, EQUIPMENTNAME, POINTNAME,SUBARRAY,startTime,endTime); List<Map<String, Object>> maps = idxBizPvHealthIndexServiceImpl.selectPointByANALYSISTYPE(STATION, HEALTHLEVEL, EQUIPMENTNAME, POINTNAME,SUBARRAY,startTime,endTime);
Map<String,Object> result = new HashMap<>(); Map<String,Object> result = new HashMap<>();
List<Object> seriesData = new ArrayList<>(); List<Object> seriesData = new ArrayList<>();
List<Object> axisData = new ArrayList<>(); List<Object> axisData = new ArrayList<>();
Collections.reverse(seriesData);
Collections.reverse(axisData);
for (Map<String, Object> map : maps) { for (Map<String, Object> map : maps) {
seriesData.add(map.get("value")); seriesData.add(map.get("value"));
axisData.add(map.get("REC_DATE")); axisData.add(map.get("REC_DATE"));
......
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