From 60e664bd398e908206d00eb8e17c3b4796c70df1 Mon Sep 17 00:00:00 2001
From: dongyukun <1208714201@qq.com>
Date: 星期一, 24 三月 2025 18:42:33 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/api/McsApiImpl.java |   24 ++++++++++--------------
 1 files changed, 10 insertions(+), 14 deletions(-)

diff --git a/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/api/McsApiImpl.java b/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/api/McsApiImpl.java
index a24443b..b4b3cfa 100644
--- a/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/api/McsApiImpl.java
+++ b/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/api/McsApiImpl.java
@@ -28,7 +28,6 @@
 import com.iailab.module.model.mcs.pre.vo.MmPredictAlarmConfigSaveReqVO;
 import com.iailab.module.model.mcs.pre.vo.MmPredictAlarmMessageSaveReqVO;
 import com.iailab.module.model.mcs.pre.vo.MmPredictItemRespVO;
-import com.iailab.module.model.mcs.sche.entity.StAdjustConfigDetEntity;
 import com.iailab.module.model.mcs.sche.entity.StScheduleModelEntity;
 import com.iailab.module.model.mcs.sche.entity.StScheduleSuggestEntity;
 import com.iailab.module.model.mcs.sche.service.*;
@@ -419,23 +418,19 @@
                 dataView.setPreDataN(mmItemResultService.getData(outPut.getId(), predictTime, endTime, timeFormat));
                 dataView.setPreDataL(mmItemResultLastPointService.getData(outPut.getId(), startTime, endTime, timeFormat));
                 break;
-            case CL:
-                dataView.setPreDataN(mmItemResultService.getData(outPut.getId(), predictTime, endTime, timeFormat));
-                dataView.setPreDataL(mmItemResultLastPointService.getData(outPut.getId(), startTime, endTime, timeFormat));
-                break;
             default:
                 break;
         }
 
         //处理预测累计
         if (outPut.getIscumulant() != null && outPut.getIscumulant() == 1) {
-            if (StringUtils.isNotBlank(outPut.getCumulpoint())) {
-                dataView.setCumulantRealData(getHisData(outPut.getCumulpoint(), predictTime, endTime));
-            }
-            List<Object[]> cumulantPreList = mmItemResultService.getData(outPut.getId() + CommonDict.CUMULANT_SUFFIX, predictTime, endTime, DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND);
+            /*if (StringUtils.isNotBlank(outPut.getCumulpoint())) {
+                dataView.setCumulantRealData(getHisData(outPut.getCumulpoint(), startTime, endTime));
+            }*/
+            List<Object[]> cumulantPreList = mmItemResultService.getData(outPut.getId() + CommonDict.CUMULANT_SUFFIX, startTime, endTime, DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND);
             dataView.setCumulantPreData(cumulantPreList);
             if (!CollectionUtils.isEmpty(cumulantPreList)) {
-                dataView.setCumulantPreValue(cumulantPreList.get(cumulantPreList.size() - 1)[1]);
+                dataView.setCumulantPreLast(new BigDecimal(cumulantPreList.get(cumulantPreList.size() - 1)[1].toString()).setScale(2, BigDecimal.ROUND_HALF_UP));
             }
         }
 
@@ -867,8 +862,9 @@
     }
 
     @Override
-    public List<Object[]> getItemResult(String outputid, Date startTime, Date endTime, String timeFormat) {
-        return mmItemResultService.getData(outputid,startTime,endTime,timeFormat);
+    public List<Object[]> getItemResult(PreItemResultReqVO reqVO) {
+
+        return mmItemResultService.getData(reqVO.getOutputid(),reqVO.getStartTime(),reqVO.getEndTime(),reqVO.getTimeFormat());
     }
 
     @Override
@@ -877,8 +873,8 @@
     }
 
     @Override
-    public List<Object[]> getItemResultLastPoint(String outputid, Date startTime, Date endTime, String timeFormat) {
-        return mmItemResultLastPointService.getData(outputid,startTime,endTime,timeFormat);
+    public List<Object[]> getItemResultLastPoint(PreItemResultReqVO reqVO) {
+        return mmItemResultLastPointService.getData(reqVO.getOutputid(),reqVO.getStartTime(),reqVO.getEndTime(),reqVO.getTimeFormat());
     }
 
     private Date[] calResultTime(ItemVO predictItem, Date startTimeReq, Date endTimeReq, int lengthLeft, int lengthRight) {

--
Gitblit v1.9.3