anderx 1 год назад
Родитель
Сommit
0367d3d257

+ 2 - 10
ruoyi-system/src/main/java/com/ruoyi/project/service/impl/ProjectStaffRecordServiceImpl.java

@@ -833,11 +833,7 @@ public class ProjectStaffRecordServiceImpl implements ProjectStaffRecordService
                                 BigDecimal added = projectDuration.add(BigDecimal.valueOf(e.getDuration()));
                                 BigDecimal checkDuration = BigDecimal.valueOf(e.getCheckDuration());
                                 map2.put("projectDuration", added);
-                                if (projectDuration.compareTo(checkDuration) >= 0){
-                                    map2.put("notDuration", BigDecimal.valueOf(0));
-                                }else {
-                                    map2.put("notDuration", checkDuration.subtract(added));
-                                }
+                                map2.put("notDuration", checkDuration.subtract(added));
                                 break;
                             }
                         }
@@ -948,11 +944,7 @@ public class ProjectStaffRecordServiceImpl implements ProjectStaffRecordService
                 BigDecimal checkDuration = BigDecimal.valueOf(e.getCheckDuration());
                 map2.put("projectDuration", projectDuration);
                 map2.put("checkDuration", checkDuration);
-                if (projectDuration.compareTo(checkDuration) >= 0){
-                    map2.put("notDuration", BigDecimal.valueOf(0));
-                }else {
-                    map2.put("notDuration", checkDuration.subtract(projectDuration));
-                }
+                map2.put("notDuration", checkDuration.subtract(projectDuration));
                 break;
             }
         }