Commit 6c76c951 authored by wujiang's avatar wujiang

修改健康指数查询

parent 3e2256aa
...@@ -144,16 +144,23 @@ public class TDBigScreenAnalyseController extends BaseController { ...@@ -144,16 +144,23 @@ public class TDBigScreenAnalyseController extends BaseController {
@ApiOperation(httpMethod = "GET", value = "场站设备健康状态指数与趋势 - 折线图", notes = "场站设备健康状态指数与趋势 - 折线图") @ApiOperation(httpMethod = "GET", value = "场站设备健康状态指数与趋势 - 折线图", notes = "场站设备健康状态指数与趋势 - 折线图")
@GetMapping(value = "/getHealthListInfo") @GetMapping(value = "/getHealthListInfo")
public ResponseModel<Map<String, Object>> getHealthListInfo(@RequestParam(required = false) String areaCode, public ResponseModel<Map<String, Object>> getHealthListInfo(@RequestParam(required = false) String areaCode,
@RequestParam(required = false) String stationCode, @RequestParam(required = false) String analysisType, @RequestParam(required = false) String stationCode, @RequestParam(required = false) String area,
@RequestParam(required = false) String station, @RequestParam(required = false) String analysisType,
@RequestParam(required = false) @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") Date startTime, @RequestParam(required = false) @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") Date startTime,
@RequestParam(required = false) @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") Date endTime) { @RequestParam(required = false) @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") Date endTime) {
if (StrUtil.isNotEmpty(stationCode)) { if (StrUtil.isNotEmpty(stationCode)) {
StationBasic stationBasic = stationBasicMapper.selectById(stationCode); StationBasic stationBasic = stationBasicMapper.selectById(stationCode);
stationCode = stationBasic.getFanGatewayId(); stationCode = stationBasic.getFanGatewayId();
} else if (StrUtil.isNotEmpty(station)) {
StationBasic stationBasic = stationBasicMapper
.selectOne(new LambdaQueryWrapper<StationBasic>().eq(StationBasic::getStationName, station));
stationCode = stationBasic.getFanGatewayId();
} }
if (StrUtil.isNotEmpty(areaCode)) { if (StrUtil.isNotEmpty(areaCode)) {
areaCode = "%" + areaCode + "%"; areaCode = "%" + areaCode + "%";
} else if (StrUtil.isNotEmpty(area)) {
areaCode = "%" + area + "%";
} }
HashMap<String, Object> resultMap = new HashMap<>(); HashMap<String, Object> resultMap = new HashMap<>();
......
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