| | |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.beans.factory.annotation.Required; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | import org.springframework.util.ObjectUtils; |
| | | import org.springframework.web.bind.annotation.CrossOrigin; |
| | | import org.springframework.web.bind.annotation.GetMapping; |
| | |
| | | return ResultMessage.ok(result); |
| | | } |
| | | |
| | | /** |
| | | * @Description: 查询市内所有县的排名 附件7 |
| | | * @Param: [regionCode, time] |
| | | * @return: com.moral.constant.ResultMessage |
| | | * @Author: 陈凯裕 |
| | | * @Date: 2022/3/16 |
| | | */ |
| | | @GetMapping("cityAreaRange") |
| | | public ResultMessage cityAreaRange(Integer regionCode,@DateTimeFormat(pattern = "yyyy-MM-dd") Date time){ |
| | | if(regionCode==null || time==null){ |
| | | return ResultMessage.fail(ResponseCodeEnum.PARAMETERS_IS_MISSING.getCode(), |
| | | ResponseCodeEnum.PARAMETERS_IS_MISSING.getMsg()); |
| | | } |
| | | CityAreaRangeVO vo = new CityAreaRangeVO(); |
| | | |
| | | ConcentrationAndPercent cap = new ConcentrationAndPercent(); |
| | | cap.setConcentration("浓度/天数/指数"); |
| | | cap.setPercent("同比"); |
| | | cap.setCompareConcentration("同比浓度"); |
| | | ConcentrationAndPercent cap2 = new ConcentrationAndPercent(); |
| | | cap2.setConcentration("浓度/天数/指数"); |
| | | cap2.setPercent("同比"); |
| | | |
| | | vo.setCityName("xxx"); |
| | | vo.setRange(0); |
| | | vo.setCompositeIndex(cap); |
| | | vo.setCO(cap); |
| | | vo.setNO2(cap); |
| | | vo.setSO2(cap); |
| | | vo.setPM10(cap); |
| | | vo.setPM25(cap); |
| | | vo.setO3(cap); |
| | | vo.setServerDays(cap2); |
| | | vo.setFineDays(cap2); |
| | | |
| | | List<CityAreaRangeVO> vos = new ArrayList<>(); |
| | | vos.add(vo); |
| | | vos.add(vo); |
| | | |
| | | return ResultMessage.ok(vos); |
| | | } |
| | | |
| | | } |