diff --git a/src/main/java/com/xkrs/controller/FirePointController.java b/src/main/java/com/xkrs/controller/FirePointController.java index 7a7549c..6080a2c 100644 --- a/src/main/java/com/xkrs/controller/FirePointController.java +++ b/src/main/java/com/xkrs/controller/FirePointController.java @@ -186,11 +186,11 @@ public class FirePointController { * @param endTime 过滤火点结束卫星时间,不传代表不指定结束时间。 * @param satelliteType 过滤传感器类型,不传代表查询全部类型的传感器 * @param landType 过滤地物类型,不传代表查询全部地物类型 - * @return 符合条件的火点列表 */ @GetMapping("/queryFirePoint") - public List queryFirePoint(@RequestParam(value = "code", required = false) String code, @RequestParam(value = "startTime", required = false) String startTime, @RequestParam(value = "endTime", required = false) String endTime, @RequestParam(value = "satelliteType", required = false) String satelliteType, @RequestParam(value = "landType", required = false) String landType) { - return firePointService.queryFirePoint(code, startTime, endTime, satelliteType, landType); + public String queryFirePoint(@RequestParam(value = "code", required = false) String code, @RequestParam(value = "startTime", required = false) String startTime, @RequestParam(value = "endTime", required = false) String endTime, @RequestParam(value = "satelliteType", required = false) String satelliteType, @RequestParam(value = "landType", required = false) String landType) { + List firePointList= firePointService.queryFirePoint(code, startTime, endTime, satelliteType, landType); + return outputEncapsulationObject(PromptMessageEnum.SUCCESS, firePointList, locale); } /** diff --git a/src/main/java/com/xkrs/service/FirePointService.java b/src/main/java/com/xkrs/service/FirePointService.java index 2bd2e7b..7b2eb75 100644 --- a/src/main/java/com/xkrs/service/FirePointService.java +++ b/src/main/java/com/xkrs/service/FirePointService.java @@ -126,6 +126,16 @@ public interface FirePointService { */ String downloadVipUserFilePoint(HttpServletRequest request, HttpServletResponse response); + /** + * 动态多条件查询火点列表 + * + * @param code 区划编码,可以是省市区县街道任意编码,如果传需要至少两位。不传代表查询全国火点 + * @param startTime 过滤火点开始卫星时间,不传代表不指定开始时间。后台会有限制。 + * @param endTime 过滤火点结束卫星时间,不传代表不指定结束时间。 + * @param satelliteType 过滤传感器类型,不传代表查询全部类型的传感器 + * @param landType 过滤地物类型,不传代表查询全部地物类型 + * @return 符合条件的火点列表 + */ List queryFirePoint(String code, String startTime, String endTime, String satelliteType, String landType); } diff --git a/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java b/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java index face48a..1a73e2a 100644 --- a/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java +++ b/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java @@ -476,6 +476,16 @@ public class FirePointServiceImpl implements FirePointService { return outputEncapsulationObject(PromptMessageEnum.SUCCESS, "ok", locale); } + /** + * 动态多条件查询火点列表 + * + * @param code 区划编码,可以是省市区县街道任意编码,如果传需要至少两位。不传代表查询全国火点 + * @param startTime 过滤火点开始卫星时间,不传代表不指定开始时间。后台会有限制。 + * @param endTime 过滤火点结束卫星时间,不传代表不指定结束时间。 + * @param satelliteType 过滤传感器类型,不传代表查询全部类型的传感器 + * @param landType 过滤地物类型,不传代表查询全部地物类型 + * @return 符合条件的火点列表 + */ @Override public List queryFirePoint(String code, String startTime, String endTime, String satelliteType, String landType) { return firePointQueryHelper.queryFirePoint(code, startTime, endTime, satelliteType, landType); diff --git a/src/main/java/com/xkrs/utils/FirePointQueryHelper.java b/src/main/java/com/xkrs/utils/FirePointQueryHelper.java index e108b8a..4a5f1a2 100644 --- a/src/main/java/com/xkrs/utils/FirePointQueryHelper.java +++ b/src/main/java/com/xkrs/utils/FirePointQueryHelper.java @@ -22,6 +22,16 @@ public class FirePointQueryHelper { @Resource private FirePointDao firePointDao; + /** + * 动态多条件查询火点列表 + * + * @param code 区划编码,可以是省市区县街道任意编码,如果传需要至少两位。不传代表查询全国火点 + * @param startTime 过滤火点开始卫星时间,不传代表不指定开始时间。后台会有限制。 + * @param endTime 过滤火点结束卫星时间,不传代表不指定结束时间。 + * @param satelliteType 过滤传感器类型,不传代表查询全部类型的传感器 + * @param landType 过滤地物类型,不传代表查询全部地物类型 + * @return 符合条件的火点列表 + */ public List queryFirePoint(String code, String startTime, String endTime, String satelliteType, String landType) { Specification specification = (root, criteriaQuery, criteriaBuilder) -> { //查询条件集合