fix(bug修复): 除基本信息外,其它信息导入后自动提交
| | |
| | | returnList.add(StrUtil.format("导入员工意外险案件异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | empAccidentcases.setDelFlag(2); |
| | | empAccidentcases.setDelFlag(0); |
| | | empAccidentcases.setEmpId(empBaseInfo.getEmpId()); |
| | | empAccidentcases.setDeptName(list.get(1).toString()); |
| | | empAccidentcases.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入员工不良记录信息异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | empBadrecord.setDelFlag(2); |
| | | empBadrecord.setDelFlag(0); |
| | | empBadrecord.setEmpId(empId); |
| | | empBadrecord.setDeptName(list.get(1).toString()); |
| | | empBadrecord.setDeptId(dept.getDeptId()); |
| | |
| | | String operatorId = Optional.of(FebsUtil.getUserId()).orElse("1"); |
| | | EmpBaseInfo dbInfo = this.getEmpBaseInfo(empBaseInfo); |
| | | Long empId = SequenceUtil.generateId(0L, ModuleCode.HR_EMPLOYEE); |
| | | boolean saveDimissionLog = false; |
| | | boolean saveDimissionLog = true; |
| | | if (dbInfo == null) { |
| | | empBaseInfo.setEmpId(empId); |
| | | saveDimissionLog = true; |
| | | // saveDimissionLog = true; |
| | | } else { |
| | | empBaseInfo.setEmpId(dbInfo.getEmpId()); |
| | | } |
| | |
| | | empBaseInfo.setModifier(operatorId); |
| | | this.saveOrUpdate(empBaseInfo); |
| | | |
| | | if(saveDimissionLog) { |
| | | EmpDimissionLog dimissionLog = new EmpDimissionLog(); |
| | | dimissionLog.setCloseId(SequenceUtil.generateId(0L, ModuleCode.HR_EMPLOYEE)); |
| | | dimissionLog.setEmpId(empId); |
| | | dimissionLog.setEntryDate(empBaseInfo.getEntryDate()); |
| | | dimissionLog.setDimissionType("20"); |
| | | dimissionLog.setRemark(empBaseInfo.getRemark()); |
| | | dimissionLog.setCreator(operatorId); |
| | | dimissionLog.setModifier(operatorId); |
| | | EmpDimissionLog dimissionLog = new EmpDimissionLog(); |
| | | dimissionLog.setCloseId(SequenceUtil.generateId(0L, ModuleCode.HR_EMPLOYEE)); |
| | | dimissionLog.setEmpId(empId); |
| | | dimissionLog.setEntryDate(empBaseInfo.getEntryDate()); |
| | | dimissionLog.setDimissionType("20"); |
| | | dimissionLog.setRemark(empBaseInfo.getRemark()); |
| | | dimissionLog.setCreator(operatorId); |
| | | dimissionLog.setModifier(operatorId); |
| | | |
| | | dimissionLogService.save(dimissionLog); |
| | | } |
| | | dimissionLogService.save(dimissionLog); |
| | | } |
| | | |
| | | @Override |
| | |
| | | returnList.add(StrUtil.format("导入员工合同信息异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | contractInfo.setDelFlag(2); |
| | | contractInfo.setDelFlag(0); |
| | | contractInfo.setEmpId(empId); |
| | | contractInfo.setDeptName(list.get(1).toString()); |
| | | contractInfo.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入离职当月考勤异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | dimissionAttend.setDelFlag(2); |
| | | dimissionAttend.setDelFlag(0); |
| | | dimissionAttend.setEmpId(empBaseInfo.getEmpId()); |
| | | dimissionAttend.setDeptName(list.get(1).toString()); |
| | | dimissionAttend.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入社保申请服务异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | empInsurance.setDelFlag(2); |
| | | empInsurance.setDelFlag(0); |
| | | empInsurance.setEmpId(empBaseInfo.getEmpId()); |
| | | empInsurance.setDeptName(list.get(1).toString()); |
| | | empInsurance.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入员工劳资案件异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | empLabortrouble.setDelFlag(2); |
| | | empLabortrouble.setDelFlag(0); |
| | | empLabortrouble.setEmpId(empBaseInfo.getEmpId()); |
| | | empLabortrouble.setDeptName(list.get(1).toString()); |
| | | empLabortrouble.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入员工请假记录异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | leaveInfo.setDelFlag(2); |
| | | leaveInfo.setDelFlag(0); |
| | | leaveInfo.setEmpId(empBaseInfo.getEmpId()); |
| | | leaveInfo.setDeptName(list.get(1).toString()); |
| | | leaveInfo.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入员工工伤案件异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | empOccupational.setDelFlag(2); |
| | | empOccupational.setDelFlag(0); |
| | | empOccupational.setEmpId(empBaseInfo.getEmpId()); |
| | | empOccupational.setDeptName(list.get(1).toString()); |
| | | empOccupational.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入员工体检信息异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | physicalExam.setDelFlag(2); |
| | | physicalExam.setDelFlag(0); |
| | | physicalExam.setEmpId(empId); |
| | | physicalExam.setDeptName(list.get(1).toString()); |
| | | physicalExam.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入员工备注信息服务异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | empRemarkinfo.setDelFlag(2); |
| | | empRemarkinfo.setDelFlag(0); |
| | | empRemarkinfo.setEmpId(empId); |
| | | empRemarkinfo.setDeptName(list.get(1).toString()); |
| | | empRemarkinfo.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入员工辞职申请异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | resign.setDelFlag(2); |
| | | resign.setDelFlag(0); |
| | | resign.setEmpId(empId); |
| | | resign.setDeptName(list.get(1).toString()); |
| | | resign.setDeptId(dept.getDeptId()); |
| | |
| | | returnList.add(StrUtil.format("导入失业金领取异常: 出现位置第{}行, 原因:{}员工编号不存在",listObject.indexOf(list)+1,list.get(0).toString())); |
| | | continue; |
| | | } |
| | | empUnemployment.setDelFlag(2); |
| | | empUnemployment.setDelFlag(0); |
| | | empUnemployment.setEmpId(empId); |
| | | empUnemployment.setDeptName(list.get(1).toString()); |
| | | empUnemployment.setDeptId(dept.getDeptId()); |
| | |
| | | workExperience.setJobContent(list.get(7).toString()); |
| | | workExperience.setCreator(FebsUtil.getUserId()); |
| | | workExperience.setModifier(FebsUtil.getUserId()); |
| | | workExperience.setDelFlag(2); |
| | | workExperience.setDelFlag(0); |
| | | this.save(workExperience); |
| | | } |
| | | } |