Просмотр исходного кода

pms 瑞都 非生产时间填写标识

zhangcl 1 день назад
Родитель
Сommit
a72277fc28

+ 19 - 0
yudao-module-pms/yudao-module-pms-biz/src/main/java/cn/iocoder/yudao/module/pms/controller/admin/iotrddailyreport/IotRdDailyReportController.java

@@ -2564,6 +2564,25 @@ public class IotRdDailyReportController {
                     reportVO.setRdStatusLabel(constructStatusPair.get(reportVO.getRdStatus()));
                 }
             }
+            BigDecimal accidentTime = reportVO.getAccidentTime();
+            BigDecimal repairTime = reportVO.getRepairTime();
+            BigDecimal selfStopTime = reportVO.getSelfStopTime();
+            BigDecimal complexityTime = reportVO.getComplexityTime();
+            BigDecimal relocationTime = reportVO.getRelocationTime();
+            BigDecimal rectificationTime = reportVO.getRectificationTime();
+            BigDecimal waitingStopTime = reportVO.getWaitingStopTime();
+            BigDecimal winterBreakTime = reportVO.getWinterBreakTime();
+            BigDecimal partyaDesignTime = reportVO.getPartyaDesign();
+            BigDecimal partyaPrepareTime = reportVO.getPartyaPrepare();
+            BigDecimal partyaResourceTime = reportVO.getPartyaResource();
+            BigDecimal otherNptTime = reportVO.getOtherNptTime();
+            if (accidentTime.compareTo(BigDecimal.ZERO) > 0 || repairTime.compareTo(BigDecimal.ZERO) > 0 || selfStopTime.compareTo(BigDecimal.ZERO) > 0
+            || complexityTime.compareTo(BigDecimal.ZERO) > 0 || relocationTime.compareTo(BigDecimal.ZERO) > 0 || rectificationTime.compareTo(BigDecimal.ZERO) > 0
+            || waitingStopTime.compareTo(BigDecimal.ZERO) > 0 || winterBreakTime.compareTo(BigDecimal.ZERO) > 0 || partyaDesignTime.compareTo(BigDecimal.ZERO) > 0
+            || partyaPrepareTime.compareTo(BigDecimal.ZERO) > 0 || partyaResourceTime.compareTo(BigDecimal.ZERO) > 0 || otherNptTime.compareTo(BigDecimal.ZERO) > 0) {
+                // 设置非生产时间填写标识
+                reportVO.setNonProductFlag(true);
+            }
             // 创建时间 格式化 yyyy-MM-dd
             if (ObjUtil.isNotEmpty(reportVO.getCreateTime())) {
                 reportVO.setCreateTimeStr(LocalDateTimeUtil.format(reportVO.getCreateTime(), DatePattern.NORM_DATE_PATTERN));

+ 3 - 0
yudao-module-pms/yudao-module-pms-biz/src/main/java/cn/iocoder/yudao/module/pms/controller/admin/iotrddailyreport/vo/IotRdDailyReportRespVO.java

@@ -168,6 +168,9 @@ public class IotRdDailyReportRespVO {
     @Schema(description = "其它非生产时间原因")
     private String otherNptReason;
 
+    @Schema(description = "非生产时间填写标识 true false")
+    private Boolean nonProductFlag = false;
+
     @Schema(description = "施工开始日期")
     private LocalDateTime constructionStartDate;