瀏覽代碼

打卡月份获取从创建时间获取修改为打卡时间获取

anderx 1 年之前
父節點
當前提交
3718db53c0

+ 9 - 5
ruoyi-system/src/main/java/com/ruoyi/project/service/impl/ProjectStaffRecordServiceImpl.java

@@ -499,8 +499,8 @@ public class ProjectStaffRecordServiceImpl implements ProjectStaffRecordService
         StringBuilder successMsg = new StringBuilder();
         StringBuilder failureMsg = new StringBuilder();
         Long companyId = deptService.selectCompanyByDeptId();
-        for (ProjectStaffRecordOut p : list)
-        {
+        List<Integer> pids=new ArrayList<Integer>();
+        for (ProjectStaffRecordOut p : list){
             try
             {
                 // 验证是否存在
@@ -561,9 +561,13 @@ public class ProjectStaffRecordServiceImpl implements ProjectStaffRecordService
                 log.error(msg, e);
             }
         }
-        if (failureNum > 0)
-        {
-            failureMsg.insert(0, "很抱歉,导入失败!共 " + failureNum + " 条数据格式不正确,错误如下:");
+        if (failureNum > 0){
+            if (failureNum<10){
+                failureMsg.insert(0, "很抱歉,导入失败!共 " + failureNum + " 条数据格式不正确,错误如下:");
+            }else {
+                failureMsg.insert(0, "很抱歉,导入失败!共 " + failureNum + " 条数据格式不正确.");
+            }
+
             throw new ServiceException(failureMsg.toString());
         }
         else