浏览代码

1.工作流插件优化

Tyx 1 月之前
父节点
当前提交
295c41d8a7

+ 6 - 2
code/jyyy/nckd-jimin-jyyy-hr/src/main/java/nckd/jimin/jyyy/hr/plugin/workflow/HRWorkflowUtils.java

@@ -27,7 +27,9 @@ public class HRWorkflowUtils {
         while(!adminType.equals("一级部门")) {
             adminDyn = BusinessDataServiceHelper.loadSingle(adminOrgId, "haos_adminorghr");
             adminType = adminDyn.getString("orgtype.name");
-            adminOrgId = adminDyn.getLong("parent.id");
+            if(!adminType.equals("一级部门")) {
+                adminOrgId = adminDyn.getLong("parent.id");
+            }
             if(adminOrgId == 0L)
                 break;
         }
@@ -46,7 +48,9 @@ public class HRWorkflowUtils {
         while(!adminType.equals("二级部门")) {
             adminDyn = BusinessDataServiceHelper.loadSingle(adminOrgId, "haos_adminorghr");
             adminType = adminDyn.getString("orgtype.name");
-            adminOrgId = adminDyn.getLong("parent.id");
+            if (!adminType.equals("二级部门")) {
+                adminOrgId = adminDyn.getLong("parent.id");
+            }
             if(adminOrgId == 0L)
                 break;
         }

+ 4 - 1
code/jyyy/nckd-jimin-jyyy-hr/src/main/java/nckd/jimin/jyyy/hr/wtc/wtam/explugin/TvlBillTimeBucketSplitExtPluginEx.java

@@ -45,8 +45,11 @@ public class TvlBillTimeBucketSplitExtPluginEx implements TvlBillTimeBucketSplit
                 LocalDate date = LocalDate.of(2025,6, 1);
                 while (shiftstartDate.compareTo((ChronoLocalDate)shiftendDate) <= 0) {
                     //正式环境 加个判断 需要大于6-1
-                    if(shiftstartDate.compareTo(date) < 0)
+                    if(shiftstartDate.compareTo(date) < 0) {
+                        log.info("shiftstartDate : " + shiftstartDate);
+                        shiftstartDate = shiftstartDate.plusDays(1L);
                         continue;
+                    }
                     LocalDateTime shiftStart = this.getshiftStartDateTime(shiftstartDate, shiftTableSingleExt);
                     LocalDateTime shiftEnd = this.getshiftEndDateTime(shiftstartDate, shiftTableSingleExt);
                     LocalDateTime shiftStartNext = this.getshiftStartDateTime(shiftstartDate.plusDays(1L), shiftTableSingleExt);