艾志工业人员信息报送逻辑修改

This commit is contained in:
Harryxzy 2024-03-12 13:27:19 +08:00
parent a85e646e9a
commit 69480c05cb
1 changed files with 5 additions and 5 deletions

View File

@ -45,7 +45,7 @@ public class EmployeeDeclareRefresh {
// if (Objects.equals(employeeDeclare.getEmploymentStatus(), EmploymentStatusEnum.ABNORMAL.getValue())
// || Objects.equals(Util.null2String(employeeDeclare.getDismissDate()), Util.null2String(salaryArchive.getPayEndDate()))) {
if (Objects.equals(employeeDeclare.getEmploymentStatus(), EmploymentStatusEnum.ABNORMAL.getValue())
|| (salaryArchive.getLastPayDate() != null && (!SalaryDateUtil.localDate2YearMonth(salaryArchive.getLastPayDate()).plusMonths(2).isAfter(SalaryDateUtil.localDate2YearMonth(dto.getTaxCycle()))) )) {
|| (salaryArchive.getLastPayDate() != null && (!SalaryDateUtil.localDate2YearMonth(salaryArchive.getLastPayDate()).plusMonths(1).isAfter(SalaryDateUtil.localDate2YearMonth(dto.getTaxCycle()))) )) {
employeeDeclare.setEmploymentStatus(EmploymentStatusEnum.ABNORMAL.getValue());
employeeDeclare.setDismissDate(salaryArchive.getLastPayDate());
employeeDeclare.setNewEmployeeInfo(1);
@ -79,9 +79,9 @@ public class EmployeeDeclareRefresh {
SalaryArchivePO salaryArchive = salaryArchiveMap.get(employeeDeclare.getEmployeeId());
// if (salaryArchive != null && (Objects.equals(salaryArchive.getRunStatus(), SalaryArchiveStatusEnum.STOP_FROM_PENDING.getValue())
// || Objects.equals(salaryArchive.getRunStatus(), SalaryArchiveStatusEnum.STOP_FROM_SUSPEND.getValue()))) {
// 校验 末次发薪日期+2 是否等于或早于当前税款所属期
// 校验 末次发薪日期+1 是否等于或早于当前税款所属期
if (salaryArchive != null && salaryArchive.getLastPayDate() != null &&
(!SalaryDateUtil.localDate2YearMonth(salaryArchive.getLastPayDate()).plusMonths(2)
(!SalaryDateUtil.localDate2YearMonth(salaryArchive.getLastPayDate()).plusMonths(1)
.isAfter(SalaryDateUtil.localDate2YearMonth(dto.getTaxCycle())) )) {
employeeDeclare.setDeclareStatus(DeclareStatusEnum.NOT_DECLARE.getValue());
employeeDeclare.setEmploymentStatus(EmploymentStatusEnum.ABNORMAL.getValue());
@ -137,9 +137,9 @@ public class EmployeeDeclareRefresh {
employeeDeclare.setEmploymentDate(salaryArchive.getPayStartDate());
// if (Objects.equals(salaryArchive.getRunStatus(), SalaryArchiveStatusEnum.STOP_FROM_PENDING.getValue())
// || Objects.equals(salaryArchive.getRunStatus(), SalaryArchiveStatusEnum.STOP_FROM_SUSPEND.getValue())) {
// 校验 末次发薪日期+2 是否等于或早于当前税款所属期
// 校验 末次发薪日期+1 是否等于或早于当前税款所属期
if (salaryArchive.getLastPayDate() != null &&
(!SalaryDateUtil.localDate2YearMonth(salaryArchive.getLastPayDate()).plusMonths(2)
(!SalaryDateUtil.localDate2YearMonth(salaryArchive.getLastPayDate()).plusMonths(1)
.isAfter(SalaryDateUtil.localDate2YearMonth(dto.getTaxCycle()))) ) {
employeeDeclare.setEmploymentStatus(EmploymentStatusEnum.ABNORMAL.getValue());
employeeDeclare.setDismissDate(salaryArchive.getLastPayDate());