Ver Fonte

pms 瑞鹰综合队修井日报 调整定时任务逻辑

zhangcl há 2 dias atrás
pai
commit
06aa2f944c

+ 3 - 3
yudao-module-pms/yudao-module-pms-biz/src/main/java/cn/iocoder/yudao/module/pms/job/dailyreport/CreateRyDailyReportOrderJob.java

@@ -168,8 +168,8 @@ public class CreateRyDailyReportOrderJob implements JobHandler {
                 // 查询当天生成的日报
                 LocalDateTime createDate = report.getCreateTime();
                 String formatDateStr = LocalDateTimeUtil.format(createDate, "yyyy-MM-dd");
-                // 除新疆综合队外的其它队伍
-                if (formatDateStr.equals(currentFormatDateStr)) {
+                // 除新疆综合队外的其它队伍 排队综合队
+                if (formatDateStr.equals(currentFormatDateStr) && !updaterPair.containsKey(report.getDeptId())) {
                     currentDayReportedDeptIds.add(report.getDeptId());
                 }
                 // 查询 新疆综合队 在明天有没有创建过日报
@@ -178,7 +178,7 @@ public class CreateRyDailyReportOrderJob implements JobHandler {
                 }
             });
         }
-
+        System.out.println("综合队明天的日报数量:" + tomorrowReportedDeptIds.size());
         // 所有的部门id
         Set<Long> reportedDeptIds = new HashSet<>();
         // 今天生成日报部门id