Commit 02a036c1 authored by hongguangwu's avatar hongguangwu

MVP1.7.1 优化预入职

parent 4625c1a3
......@@ -455,6 +455,7 @@ public class TEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "开户行总行不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行总行")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankName;
/**
* 开户行省
......@@ -462,6 +463,7 @@ public class TEmployeeInfo extends BaseEntity {
@ExcelAttribute(name = "开户行省",isArea = true)
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行省")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankProvince;
/**
* 开户行市
......@@ -469,6 +471,7 @@ public class TEmployeeInfo extends BaseEntity {
@ExcelAttribute(name = "开户行市",isArea = true,parentField = "bankProvince")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行市")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankCity;
/**
* 开户行支行
......@@ -477,6 +480,7 @@ public class TEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "开户行支行不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("开户行支行")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankSubName;
/**
* 银行卡号
......@@ -485,6 +489,7 @@ public class TEmployeeInfo extends BaseEntity {
@Length(max = 50, message = "银行卡号不能超过50个字符")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("银行卡号")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String bankNo;
/**
* 计税月份
......@@ -493,6 +498,7 @@ public class TEmployeeInfo extends BaseEntity {
@Length(max = 6, message = "计税月份不能超过6个字符")
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty("计税月份")
@TableField(updateStrategy = FieldStrategy.IGNORED)
private String taxMonth;
/**
* 通信地址省
......
......@@ -219,10 +219,10 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
}
// 审核通过并且有在项,取在项
boolean empFirst = false;
if (main != null) {
if (CommonConstants.FOUR_STRING.equals(main.getStatus()) && employee != null && project != null) {
if ((main == null || (main != null && CommonConstants.FOUR_STRING.equals(main.getStatus()))) && employee != null && project != null) {
empFirst = true;
}
if (main != null) {
// 2024-7-3 17:23:50 倩倩要求放开状态拦截,前端加按钮禁用即可
/* (CommonConstants.ONE_STRING.equals(main.getStatus())
|| CommonConstants.TWO_STRING.equals(main.getStatus()))
......@@ -426,7 +426,7 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
tPreEmpBadRecord.setCreateBy(user.getId());
tPreEmpBadRecord.setCreateName(user.getNickname());
tPreEmpBadRecord.setCreateTime(LocalDateTime.now());
if (Common.isEmpty(preId)) {
if (Common.isEmpty(preId) && !empFirst) {
tPreEmpBadRecordService.save(tPreEmpBadRecord);
}
}
......@@ -455,7 +455,7 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
tPreEmpContactInfo.setCreateBy(user.getId());
tPreEmpContactInfo.setCreateName(user.getNickname());
tPreEmpContactInfo.setCreateTime(LocalDateTime.now());
if (Common.isEmpty(preId)) {
if (Common.isEmpty(preId) && !empFirst) {
tPreEmpContactInfoService.save(tPreEmpContactInfo);
}
}
......@@ -491,7 +491,7 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
tPreEmpDisabilityInfo.setCreateBy(user.getId());
tPreEmpDisabilityInfo.setCreateName(user.getNickname());
tPreEmpDisabilityInfo.setCreateTime(LocalDateTime.now());
if (Common.isEmpty(preId)) {
if (Common.isEmpty(preId) && !empFirst) {
tPreEmpDisabilityInfoService.save(tPreEmpDisabilityInfo);
}
}
......@@ -538,7 +538,7 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
tPreEmpEducation.setCreateBy(user.getId());
tPreEmpEducation.setCreateName(user.getNickname());
tPreEmpEducation.setCreateTime(LocalDateTime.now());
if (Common.isEmpty(preId)) {
if (Common.isEmpty(preId) && !empFirst) {
tPreEmpEducationService.save(tPreEmpEducation);
}
} else {
......@@ -1068,6 +1068,7 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
tPreEmployeeInfo.setTaxMonth(tSalaryEmployee.getTaxMonth());
}
} else {
tPreEmployeeInfo.setBankNo(null);
tPreEmployeeInfo.setBankName(null);
tPreEmployeeInfo.setBankSubName(null);
tPreEmployeeInfo.setBankProvince(null);
......@@ -1730,6 +1731,13 @@ public class TPreEmpMainServiceImpl extends ServiceImpl<TPreEmpMainMapper, TPreE
}
// 有在项,则更新薪资人员
boolean isMustUpdateSalary = false;
if (tPreEmployeeInfo != null && Common.isEmpty(tPreEmployeeInfo.getBankNo())) {
tPreEmployeeInfo.setBankName(null);
tPreEmployeeInfo.setBankSubName(null);
tPreEmployeeInfo.setBankProvince(null);
tPreEmployeeInfo.setBankCity(null);
tPreEmployeeInfo.setTaxMonth(null);
}
if (tPreEmployeeInfo != null && Common.isNotNull(tPreEmployeeInfo.getOldId())
&& Common.isNotNull(tPreEmployeeProject.getOldId())) {
empId = tPreEmployeeInfo.getOldId();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment