From ab86c5e1ad56841b8a8f832440e261fca5634800 Mon Sep 17 00:00:00 2001
From: liurunyu <lry9898@163.com>
Date: 星期五, 29 八月 2025 11:48:45 +0800
Subject: [PATCH] 水肥机数据Vo对象增加数值字段对应字符串字段的映射
---
pipIrr-platform/pipIrr-web/pipIrr-web-remote/src/main/java/com/dy/pipIrrRemote/mqttSd1/soil/SoilCtrl.java | 20 ++++++++++++++++----
1 files changed, 16 insertions(+), 4 deletions(-)
diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-remote/src/main/java/com/dy/pipIrrRemote/mqttSd1/soil/SoilCtrl.java b/pipIrr-platform/pipIrr-web/pipIrr-web-remote/src/main/java/com/dy/pipIrrRemote/mqttSd1/soil/SoilCtrl.java
index 0877929..2478f0d 100644
--- a/pipIrr-platform/pipIrr-web/pipIrr-web-remote/src/main/java/com/dy/pipIrrRemote/mqttSd1/soil/SoilCtrl.java
+++ b/pipIrr-platform/pipIrr-web/pipIrr-web-remote/src/main/java/com/dy/pipIrrRemote/mqttSd1/soil/SoilCtrl.java
@@ -104,6 +104,7 @@
if(qo.soilId == null){
return BaseResponseUtils.buildFail("澧掓儏绔檌d涓嶈兘涓虹┖") ;
}
+ qo.completionTime();
return BaseResponseUtils.buildSuccess(sv.someDay(qo));
} catch (Exception e) {
return BaseResponseUtils.buildException(e.getMessage()) ;
@@ -142,15 +143,24 @@
/**
* 鏍规嵁鎸囧畾鏉′欢鏌ヨ鍘嗗彶璁板綍
- * @param soilId
+ * @param qo
* @return
*/
@GetMapping(path = "oneHistory")
@SsoAop()
- public BaseResponse<QueryResultVo<List<VoSoil>>> oneHistory(Long soilId){
+ public BaseResponse<QueryResultVo<List<VoSoil>>> oneHistory(SoilQo qo){
try {
-
- return BaseResponseUtils.buildSuccess(sv.oneHistory(soilId));
+ if(qo.soilId == null){
+ return BaseResponseUtils.buildFail("澧掓儏绔檌d涓嶈兘涓虹┖") ;
+ }
+ String dtStart = qo.timeStart ;
+ qo.completionTime();
+ if(qo.timeStop == null || qo.timeStop.trim().equals("")){
+ if(dtStart != null && !dtStart.trim().equals("")){
+ qo.timeStop = dtStart + " 23:59:59";
+ }
+ }
+ return BaseResponseUtils.buildSuccess(sv.oneHistory(qo));
} catch (Exception e) {
return BaseResponseUtils.buildException(e.getMessage()) ;
}
@@ -166,6 +176,7 @@
@SsoAop()
public BaseResponse<QueryResultVo<List<VoSoil>>> someLast(SoilQo qo){
try {
+ qo.completionTime();
return BaseResponseUtils.buildSuccess(sv.someLast(qo));
} catch (Exception e) {
return BaseResponseUtils.buildException(e.getMessage()) ;
@@ -181,6 +192,7 @@
@SsoAop()
public BaseResponse<QueryResultVo<List<VoSoil>>> someHistory(SoilQo qo){
try {
+ qo.completionTime();
return BaseResponseUtils.buildSuccess(sv.someHistory(qo));
} catch (Exception e) {
return BaseResponseUtils.buildException(e.getMessage()) ;
--
Gitblit v1.8.0