|
|
@@ -489,7 +489,7 @@ public class LedgerCombinedImportServiceImpl implements ILedgerCombinedImportSer
|
|
489
|
489
|
/** 6. 安保测试记录表(部门)→ ledger_security_test
|
|
490
|
490
|
* 导入顺序:开展时间(0) 测试区域(1) 测试通道(2) 测试人员(3) 测试项目(4)
|
|
491
|
491
|
* 被测试人员(5) 被测试岗位(6) 测试物品(7) 图片或视频(8) 是否通过(9)
|
|
492
|
|
- * 层级(10) 整改措施(11) (12空) 整改材料(13)
|
|
|
492
|
+ * 层级(10) 整改措施(11) 整改材料(12)
|
|
493
|
493
|
*/
|
|
494
|
494
|
private int doSecurityTest(Sheet sheet, String batchNo, String username) {
|
|
495
|
495
|
List<LedgerSecurityTest> list = new ArrayList<>();
|
|
|
@@ -509,7 +509,7 @@ public class LedgerCombinedImportServiceImpl implements ILedgerCombinedImportSer
|
|
509
|
509
|
o.setProblemDesc(str(c, 9)); // 是否通过
|
|
510
|
510
|
o.setTestLevel(str(c, 10)); // 层级
|
|
511
|
511
|
o.setResultHandling(str(c, 11)); // 整改措施
|
|
512
|
|
- o.setReviewMaterial(str(c, 13)); // 整改材料
|
|
|
512
|
+ o.setReviewMaterial(str(c, 12)); // 整改材料
|
|
513
|
513
|
|
|
514
|
514
|
// 使用缓存查找组织信息(根据被测人名称)
|
|
515
|
515
|
if (testedName != null && !testedName.trim().isEmpty()) {
|
|
|
@@ -891,19 +891,34 @@ public class LedgerCombinedImportServiceImpl implements ILedgerCombinedImportSer
|
|
891
|
891
|
// }
|
|
892
|
892
|
|
|
893
|
893
|
/** 14. 请、休假记录表(特殊)→ ledger_leave_special
|
|
894
|
|
- * R2: 姓名(0) 班组(1) 时间(起)(2) 时间(止)(3) 休假类别(4) 天数/时长(5)
|
|
|
894
|
+ * R2: 姓名(0) 时间(起)(1) 时间(止)(2) 休假类别(3) 天数/时长(4)
|
|
895
|
895
|
* 天数/时长列可能是纯数字(天)或"X小时"格式;小时值按8小时/天换算成天数
|
|
896
|
896
|
*/
|
|
897
|
897
|
private int doLeaveSpecial(Sheet sheet, String batchNo, String username) {
|
|
898
|
898
|
List<LedgerLeaveSpecial> list = new ArrayList<>();
|
|
899
|
899
|
for (Object[] c : dataRows(sheet, 2)) {
|
|
900
|
900
|
LedgerLeaveSpecial o = new LedgerLeaveSpecial();
|
|
901
|
|
- o.setPersonName(str(c, 0));
|
|
902
|
|
- o.setTeamName(str(c, 1));
|
|
903
|
|
- o.setLeaveType(str(c, 4));
|
|
904
|
|
- o.setStartDate(date(c, 2));
|
|
905
|
|
- o.setEndDate(date(c, 3));
|
|
906
|
|
- o.setDays(hoursOrDays(c, 5));
|
|
|
901
|
+ String personName = str(c, 0);
|
|
|
902
|
+ o.setPersonName(personName);
|
|
|
903
|
+ o.setStartDate(date(c, 1));
|
|
|
904
|
+ o.setEndDate(date(c, 2));
|
|
|
905
|
+ o.setLeaveType(str(c, 3));
|
|
|
906
|
+ o.setDays(hoursOrDays(c, 4));
|
|
|
907
|
+
|
|
|
908
|
+ // 根据姓名查找组织信息
|
|
|
909
|
+ if (personName != null && !personName.trim().isEmpty()) {
|
|
|
910
|
+ Map<String, Object> orgInfo = resolveOrgInfoByNameWithCache(personName);
|
|
|
911
|
+ if (!orgInfo.isEmpty()) {
|
|
|
912
|
+ o.setPersonUserId((Long) orgInfo.get("userId"));
|
|
|
913
|
+ o.setDeptId((Long) orgInfo.get("deptId"));
|
|
|
914
|
+ o.setDeptName((String) orgInfo.get("deptName"));
|
|
|
915
|
+ o.setTeamId((Long) orgInfo.get("teamId"));
|
|
|
916
|
+ o.setTeamName((String) orgInfo.get("teamName"));
|
|
|
917
|
+ o.setGroupId((Long) orgInfo.get("groupId"));
|
|
|
918
|
+ o.setGroupName((String) orgInfo.get("groupName"));
|
|
|
919
|
+ }
|
|
|
920
|
+ }
|
|
|
921
|
+
|
|
907
|
922
|
o.setImportBatch(batchNo);
|
|
908
|
923
|
o.setSourceType("1");
|
|
909
|
924
|
o.setCreateBy(username);
|