Commit fa921ab6 authored by huyuchen's avatar huyuchen

划转修改

parent 1dba38d2
...@@ -143,6 +143,13 @@ public class TEmployeeProject extends BaseEntity { ...@@ -143,6 +143,13 @@ public class TEmployeeProject extends BaseEntity {
@TableField(exist = false) @TableField(exist = false)
private Integer isLeaveEmployee; private Integer isLeaveEmployee;
/**
* 已产生未结算费用 0:划转 1:不划转
*/
@Schema(description ="已产生未结算费用(0:划转 1:不划转)")
@TableField(exist = false)
private String unsettleDeal;
/** /**
* 员工编码 * 员工编码
*/ */
......
...@@ -39,6 +39,7 @@ import com.yifu.cloud.plus.v1.yifu.common.core.util.R; ...@@ -39,6 +39,7 @@ import com.yifu.cloud.plus.v1.yifu.common.core.util.R;
import com.yifu.cloud.plus.v1.yifu.common.dapr.util.SocialDaprUtils; import com.yifu.cloud.plus.v1.yifu.common.dapr.util.SocialDaprUtils;
import com.yifu.cloud.plus.v1.yifu.salary.vo.UpdateSocialFoundVo; import com.yifu.cloud.plus.v1.yifu.salary.vo.UpdateSocialFoundVo;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.validation.BindingResult; import org.springframework.validation.BindingResult;
...@@ -63,6 +64,7 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper, ...@@ -63,6 +64,7 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
private final TEmployeeLogServiceImpl tEmployeeLogService; private final TEmployeeLogServiceImpl tEmployeeLogService;
@Autowired
private final SocialDaprUtils socialDaprUtils; private final SocialDaprUtils socialDaprUtils;
public static final Pattern PATTERN = Pattern.compile("^[-\\+]?[\\d]*$"); public static final Pattern PATTERN = Pattern.compile("^[-\\+]?[\\d]*$");
...@@ -114,7 +116,6 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper, ...@@ -114,7 +116,6 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
// 记录变更日志 // 记录变更日志
tEmployeeLogService.saveModificationRecord(CommonConstants.dingleDigitIntArray[1], "", updateTEmployeeProject.getId(), tEmployeeProjectOld, updateTEmployeeProject); tEmployeeLogService.saveModificationRecord(CommonConstants.dingleDigitIntArray[1], "", updateTEmployeeProject.getId(), tEmployeeProjectOld, updateTEmployeeProject);
UpdateSocialFoundVo updateSocialFoundVo = new UpdateSocialFoundVo(); UpdateSocialFoundVo updateSocialFoundVo = new UpdateSocialFoundVo();
updateSocialFoundVo.setEmpIdcard(updateTEmployeeProject.getEmpIdcard()); updateSocialFoundVo.setEmpIdcard(updateTEmployeeProject.getEmpIdcard());
updateSocialFoundVo.setSettleDomainCode(updateTEmployeeProject.getDeptNo()); updateSocialFoundVo.setSettleDomainCode(updateTEmployeeProject.getDeptNo());
...@@ -122,14 +123,16 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper, ...@@ -122,14 +123,16 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
updateSocialFoundVo.setSettleDomainName(updateTEmployeeProject.getDeptName()); updateSocialFoundVo.setSettleDomainName(updateTEmployeeProject.getDeptName());
updateSocialFoundVo.setUnitId(updateTEmployeeProject.getUnitId()); updateSocialFoundVo.setUnitId(updateTEmployeeProject.getUnitId());
updateSocialFoundVo.setUnitName(updateTEmployeeProject.getUnitName()); updateSocialFoundVo.setUnitName(updateTEmployeeProject.getUnitName());
updateSocialFoundVo.setSocialCreateMonth(tEmpChangeInfo.getChangeStartMonth()); if (CommonConstants.ONE_STRING.equals(tEmpChangeInfo.getUnsettleDeal())) {
updateSocialFoundVo.setSocialCreateMonth(tEmpChangeInfo.getChangeStartMonth().replace("-",""));
socialDaprUtils.updatePaymentSocialAndFound(updateSocialFoundVo); socialDaprUtils.updatePaymentSocialAndFound(updateSocialFoundVo);
socialDaprUtils.updateForSocialAndFound(updateSocialFoundVo); socialDaprUtils.updateForSocialAndFound(updateSocialFoundVo);
if (!CommonConstants.ZERO_STRING.equals(updateTEmployeeProject.getSocialStatus())) { }
if (CommonConstants.ZERO_INT != updateTEmployeeProject.getSocialStatus()) {
updateSocialFoundVo.setFlag(CommonConstants.ZERO_STRING); updateSocialFoundVo.setFlag(CommonConstants.ZERO_STRING);
socialDaprUtils.updateSocialAndFoundInfo(updateSocialFoundVo); socialDaprUtils.updateSocialAndFoundInfo(updateSocialFoundVo);
} }
if (!CommonConstants.ZERO_STRING.equals(updateTEmployeeProject.getFundStatus())) { if (CommonConstants.ZERO_INT != updateTEmployeeProject.getFundStatus()) {
updateSocialFoundVo.setFlag(CommonConstants.ONE_STRING); updateSocialFoundVo.setFlag(CommonConstants.ONE_STRING);
socialDaprUtils.updateSocialAndFoundInfo(updateSocialFoundVo); socialDaprUtils.updateSocialAndFoundInfo(updateSocialFoundVo);
} }
...@@ -221,6 +224,7 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper, ...@@ -221,6 +224,7 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
updateTEmployeePro.setUnitName(tCustomerInfo.getCustomerName()); updateTEmployeePro.setUnitName(tCustomerInfo.getCustomerName());
} }
updateTEmployeePro.setChangeStartMonth(excel.getChangeStartMonth()); updateTEmployeePro.setChangeStartMonth(excel.getChangeStartMonth());
updateTEmployeePro.setUnsettleDeal(excel.getUnsettleDeal());
updateList.add(updateTEmployeePro); updateList.add(updateTEmployeePro);
// 记录变更日志 // 记录变更日志
tEmployeeLogService.saveModificationRecord(CommonConstants.dingleDigitIntArray[1], "", tEmployeeProjectOld.getId(), tEmployeeProjectOld, updateTEmployeePro); tEmployeeLogService.saveModificationRecord(CommonConstants.dingleDigitIntArray[1], "", tEmployeeProjectOld.getId(), tEmployeeProjectOld, updateTEmployeePro);
...@@ -246,14 +250,16 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper, ...@@ -246,14 +250,16 @@ public class TEmpChangeInfoServiceImpl extends ServiceImpl<TEmpChangeInfoMapper,
updateSocialFoundVo.setUnitId(tEmployeeProject.getUnitId()); updateSocialFoundVo.setUnitId(tEmployeeProject.getUnitId());
updateSocialFoundVo.setUnitName(tEmployeeProject.getUnitName()); updateSocialFoundVo.setUnitName(tEmployeeProject.getUnitName());
updateSocialFoundVo.setSettleDomainName(tEmployeeProject.getDeptName()); updateSocialFoundVo.setSettleDomainName(tEmployeeProject.getDeptName());
if (CommonConstants.IS_CHANGE.equals(tEmployeeProject.getUnsettleDeal())) {
updateSocialFoundVo.setSocialCreateMonth(tEmployeeProject.getChangeStartMonth()); updateSocialFoundVo.setSocialCreateMonth(tEmployeeProject.getChangeStartMonth());
socialDaprUtils.updatePaymentSocialAndFound(updateSocialFoundVo); socialDaprUtils.updatePaymentSocialAndFound(updateSocialFoundVo);
socialDaprUtils.updateForSocialAndFound(updateSocialFoundVo); socialDaprUtils.updateForSocialAndFound(updateSocialFoundVo);
if (!CommonConstants.ZERO_STRING.equals(tEmployeeProject.getSocialStatus())) { }
if (CommonConstants.ZERO_INT != tEmployeeProject.getSocialStatus()) {
updateSocialFoundVo.setFlag(CommonConstants.ZERO_STRING); updateSocialFoundVo.setFlag(CommonConstants.ZERO_STRING);
socialDaprUtils.updateSocialAndFoundInfo(updateSocialFoundVo); socialDaprUtils.updateSocialAndFoundInfo(updateSocialFoundVo);
} }
if (!CommonConstants.ZERO_STRING.equals(tEmployeeProject.getFundStatus())) { if (CommonConstants.ZERO_INT != tEmployeeProject.getFundStatus()) {
updateSocialFoundVo.setFlag(CommonConstants.ONE_STRING); updateSocialFoundVo.setFlag(CommonConstants.ONE_STRING);
socialDaprUtils.updateSocialAndFoundInfo(updateSocialFoundVo); socialDaprUtils.updateSocialAndFoundInfo(updateSocialFoundVo);
} }
......
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