From eb5a6e5a54efa997971beffc909bcadc06dc8886 Mon Sep 17 00:00:00 2001 From: liurunyu <lry9898@163.com> Date: 星期一, 21 四月 2025 10:45:16 +0800 Subject: [PATCH] 1、江海测试系统设备类型默认为阀; 2、完善通信中间件测试消息推送代码; 3、增加队列数据结构注释; 4、121服务器相关的初始化配置文件bug修改; 5、其他注释完善。 --- pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/irrigation/IrrigationCtrl.java | 38 +++++++++++++++++++------------------- 1 files changed, 19 insertions(+), 19 deletions(-) diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/irrigation/IrrigationCtrl.java b/pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/irrigation/IrrigationCtrl.java index e2ffc0d..6962e05 100644 --- a/pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/irrigation/IrrigationCtrl.java +++ b/pipIrr-platform/pipIrr-web/pipIrr-web-wechat/src/main/java/com/dy/pipIrrWechat/irrigation/IrrigationCtrl.java @@ -4,8 +4,9 @@ import com.dy.common.webUtil.BaseResponseUtils; import com.dy.common.webUtil.QueryResultVo; import com.dy.pipIrrGlobal.voIr.VoGroupSimple; -import com.dy.pipIrrGlobal.voIr.VoUnitSimple; -import com.dy.pipIrrWechat.irrigation.qo.QoClient; +import com.dy.pipIrrGlobal.voIr.VoProjectSimple; +import com.dy.pipIrrWechat.irrigation.qo.QoGroup; +import com.dy.pipIrrWechat.irrigation.qo.QoProject; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.web.bind.annotation.GetMapping; @@ -28,34 +29,33 @@ public class IrrigationCtrl { private final IrrigationSv irrigationSv; + /** - * 鏍规嵁鍐滄埛缂栧彿鑾峰彇杞亴缁勫垪琛� - * @param vo + * 鏍规嵁鍐滄埛缂栧彿鑾峰彇鐏屾簤鍗曞厓鍒楄〃 + * @param qo * @return */ - @GetMapping(path = "/getGroups") - public BaseResponse<QueryResultVo<List<VoGroupSimple>>> getGroups(QoClient vo) { + @GetMapping(path = "/getSimpleProjects") + public BaseResponse<List<VoProjectSimple>> getSimpleProjects(QoProject qo) { try { - QueryResultVo<List<VoGroupSimple>> res = irrigationSv.getGroupsByClientId(vo); - return BaseResponseUtils.buildSuccess(res); + return BaseResponseUtils.buildSuccess(irrigationSv.getSimpleProjects(qo)); } catch (Exception e) { - log.error("鑾峰彇杞亴缁勮褰曞紓甯�", e); + log.error("鑾峰彇椤圭洰璁板綍寮傚父", e); return BaseResponseUtils.buildException(e.getMessage()); } } - /** - * 鏍规嵁鍐滄埛缂栧彿鑾峰彇鐏屾簤鍗曞厓鍒楄〃 - * @param vo - * @return - */ - @GetMapping(path = "/getUnits") - public BaseResponse<QueryResultVo<List<VoUnitSimple>>> getUnits(QoClient vo) { + @GetMapping(path = "/getSimpleGroups") + public BaseResponse<List<VoGroupSimple>> getSimpleGroups(QoGroup qo) { + if(qo.getProjectId() == null) { + return BaseResponseUtils.buildErrorMsg("璇烽�夋嫨椤圭洰"); + } + try { - QueryResultVo<List<VoUnitSimple>> res = irrigationSv.getUnitsByClientId(vo); - return BaseResponseUtils.buildSuccess(res); + //QueryResultVo<List<VoGroupSimple>> res = irrigationSv.getSimpleGroups(qo); + return BaseResponseUtils.buildSuccess(irrigationSv.getSimpleGroups(qo)); } catch (Exception e) { - log.error("鑾峰彇鐏屾簤鍗曞厓璁板綍寮傚父", e); + log.error("鑾峰彇杞亴缁勮褰曞紓甯�", e); return BaseResponseUtils.buildException(e.getMessage()); } } -- Gitblit v1.8.0