Commit 4cc368cb authored by fangxinjiang's avatar fangxinjiang

Merge remote-tracking branch 'origin/MVP1.7.17' into MVP1.7.17

parents 85a1aa04 aa6997cb
...@@ -591,6 +591,11 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe ...@@ -591,6 +591,11 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe
return R.failed("无需处理原因超过200字!"); return R.failed("无需处理原因超过200字!");
} }
if (leave != null) { if (leave != null) {
BaseSearchVO returnVo;
BaseSearchVO paramVo = new BaseSearchVO();
paramVo.setEmpIdCard(registration.getEmpIdcard());
paramVo.setDeptNo(registration.getDeptNo());
StringBuilder errorInfo = new StringBuilder(); StringBuilder errorInfo = new StringBuilder();
StringBuilder logInfo = new StringBuilder("手动关闭:"); StringBuilder logInfo = new StringBuilder("手动关闭:");
if (Common.isNotNull(doTypeWu)) { if (Common.isNotNull(doTypeWu)) {
...@@ -611,9 +616,22 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe ...@@ -611,9 +616,22 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe
&& !CommonConstants.EIGHT_STRING.equals(leave.getDoStatusEmp())) { && !CommonConstants.EIGHT_STRING.equals(leave.getDoStatusEmp())) {
leave.setCloseRemarkEmp(remark); leave.setCloseRemarkEmp(remark);
leave.setDoStatusEmp(CommonConstants.ONE_STRING); leave.setDoStatusEmp(CommonConstants.ONE_STRING);
String isMultipleDept = CommonConstants.ZERO_STRING;
R<BaseSearchVO> returnR = archivesDaprUtil.getEmpAndContractStatus(paramVo);
if (null != returnR && Common.isNotNull(returnR.getData())) {
returnVo = returnR.getData();
if (Common.isNotNull(returnVo.getResultIdFour())) {
isMultipleDept = returnVo.getResultIdFour();
}
}
if (CommonConstants.ZERO_STRING.equals(isMultipleDept)) {
errorInfo.append("人员当下非多项目,不可无需处理!");
}
} else { } else {
errorInfo.append("人员档案状态已完结,不可无需处理!"); errorInfo.append("人员档案状态已完结,不可无需处理!");
} }
} }
} }
if (Common.isNotNull(doTypeYi)) { if (Common.isNotNull(doTypeYi)) {
...@@ -621,10 +639,6 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe ...@@ -621,10 +639,6 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe
logInfo.append("已在其他入口处理:"); logInfo.append("已在其他入口处理:");
String socialDispatchId = ""; String socialDispatchId = "";
String fundDispatchId = ""; String fundDispatchId = "";
BaseSearchVO returnVo;
BaseSearchVO paramVo = new BaseSearchVO();
paramVo.setEmpIdCard(registration.getEmpIdcard());
paramVo.setDeptNo(registration.getDeptNo());
R<BaseSearchVO> returnR = socialDaprUtils.getSocialAndFundStatusByClose(paramVo); R<BaseSearchVO> returnR = socialDaprUtils.getSocialAndFundStatusByClose(paramVo);
if (null != returnR && Common.isNotNull(returnR.getData())) { if (null != returnR && Common.isNotNull(returnR.getData())) {
returnVo = returnR.getData(); returnVo = returnR.getData();
...@@ -917,6 +931,7 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe ...@@ -917,6 +931,7 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe
leave.setDoStatusInsurance(CommonConstants.TWO_STRING); leave.setDoStatusInsurance(CommonConstants.TWO_STRING);
} else { } else {
this.removeInsuranceToDoType(leave); this.removeInsuranceToDoType(leave);
leave.setDoStatusInsurance(CommonConstants.ONE_STRING);
} }
} }
// 停缴社保日期 // 停缴社保日期
...@@ -1404,78 +1419,92 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe ...@@ -1404,78 +1419,92 @@ public class EmployeeRegistrationLeaveServiceImpl extends ServiceImpl<EmployeeRe
} }
// 项目-完成 // 项目-完成
if (!listParamProject.isEmpty()) { if (!listParamProject.isEmpty()) {
BaseSearchListVO paramVoProject = new BaseSearchListVO(); projectParamList = new ArrayList<>();
paramVoProject.setUserId(user.getId()); List<BaseSearchVO> tempProject;
paramVoProject.setUserName(user.getNickname()); BaseSearchListVO paramVoProject;
paramVoProject.setListParam(listParamProject); for (BaseSearchVO proVo : listParamProject) {
R<BaseSearchListVO> listR = archivesDaprUtil.leaveToReduceProject(paramVoProject); tempProject = new ArrayList<>();
if (Common.isNotNull(listR) && Common.isNotNull(listR.getData())) { tempProject.add(proVo);
// 部分失败 paramVoProject = new BaseSearchListVO();
if (!listR.getData().getErrorMessageList().isEmpty()) { paramVoProject.setUserId(user.getId());
paramVoProject.setUserName(user.getNickname());
paramVoProject.setListParam(tempProject);
R<BaseSearchListVO> listR = archivesDaprUtil.leaveToReduceProject(paramVoProject);
if (Common.isNotNull(listR) && Common.isNotNull(listR.getData()) && !listR.getData().getErrorMessageList().isEmpty()) {
projectParamList = listR.getData().getErrorMessageList(); projectParamList = listR.getData().getErrorMessageList();
Map<String, String> errorMap = new HashMap<>(); }
for (ErrorMessage message : projectParamList) { }
errorMap.put(message.getKey(), message.getMessage()); if (!projectParamList.isEmpty()) {
} Map<String, String> errorMap = new HashMap<>();
for (EmployeeRegistrationLeave leave : leaveList) { for (ErrorMessage message : projectParamList) {
if (judgeToUpdateProject(doType, leave) ) { errorMap.put(message.getKey(), message.getMessage());
if (errorMap.get(leave.getId()) != null) { }
errorMessage = errorMap.get(leave.getId()); for (EmployeeRegistrationLeave leave : leaveList) {
if (Common.isNotNull(errorMessage) && errorMessage.length() > 300) { if (judgeToUpdateProject(doType, leave)) {
errorMessage = errorMessage.substring(0, 300); if (errorMap.get(leave.getId()) != null) {
} errorMessage = errorMap.get(leave.getId());
leave.setFailEmpProjectRemark(errorMessage); if (Common.isNotNull(errorMessage) && errorMessage.length() > 300) {
leave.setFailEmpProjectTime(LocalDateTime.now()); errorMessage = errorMessage.substring(0, 300);
leave.setDoStatusProject(CommonConstants.NINE_STRING);
} }
leave.setFailEmpProjectRemark(errorMessage);
leave.setFailEmpProjectTime(LocalDateTime.now());
leave.setDoStatusProject(CommonConstants.NINE_STRING);
} }
} }
} else { }
// 全部成功 } else {
for (EmployeeRegistrationLeave leave : leaveList) { // 全部成功
if (judgeToUpdateProject(doType, leave) ) { for (EmployeeRegistrationLeave leave : leaveList) {
leave.setEmpProjectId(leave.getEmpProjectIdOld()); if (judgeToUpdateProject(doType, leave)) {
leave.setDoStatusProject(CommonConstants.EIGHT_STRING); leave.setEmpProjectId(leave.getEmpProjectIdOld());
} leave.setDoStatusProject(CommonConstants.EIGHT_STRING);
} }
} }
} }
} }
// 员工-完成 // 员工-完成
if (!listParamEmp.isEmpty()) { if (!listParamEmp.isEmpty()) {
BaseSearchListVO paramVoEmp = new BaseSearchListVO();
paramVoEmp.setUserId(user.getId()); empParamList = new ArrayList<>();
paramVoEmp.setUserName(user.getNickname()); List<BaseSearchVO> tempEmp;
paramVoEmp.setListParam(listParamEmp); BaseSearchListVO paramVoEmp;
R<BaseSearchListVO> listR = archivesDaprUtil.leaveToReduceEmp(paramVoEmp); for (BaseSearchVO empVo : listParamEmp) {
if (Common.isNotNull(listR) && Common.isNotNull(listR.getData())) {
// 部分失败 tempEmp = new ArrayList<>();
if (!listR.getData().getErrorMessageList().isEmpty()) { tempEmp.add(empVo);
paramVoEmp = new BaseSearchListVO();
paramVoEmp.setUserId(user.getId());
paramVoEmp.setUserName(user.getNickname());
paramVoEmp.setListParam(tempEmp);
R<BaseSearchListVO> listR = archivesDaprUtil.leaveToReduceEmp(paramVoEmp);
if (Common.isNotNull(listR) && Common.isNotNull(listR.getData()) && !listR.getData().getErrorMessageList().isEmpty()) {
empParamList = listR.getData().getErrorMessageList(); empParamList = listR.getData().getErrorMessageList();
Map<String, String> errorMap = new HashMap<>(); }
for (ErrorMessage message : empParamList) { }
errorMap.put(message.getKey(), message.getMessage()); if (!empParamList.isEmpty()) {
} Map<String, String> errorMap = new HashMap<>();
for (EmployeeRegistrationLeave leave : leaveList) { for (ErrorMessage message : empParamList) {
if (judgeToUpdateEmp(doType, leave) ) { errorMap.put(message.getKey(), message.getMessage());
if (errorMap.get(leave.getId()) != null) { }
errorMessage = errorMap.get(leave.getId()); for (EmployeeRegistrationLeave leave : leaveList) {
if (Common.isNotNull(errorMessage) && errorMessage.length() > 300) { if (judgeToUpdateEmp(doType, leave)) {
errorMessage = errorMessage.substring(0, 300); if (errorMap.get(leave.getId()) != null) {
} errorMessage = errorMap.get(leave.getId());
leave.setFailEmpRemark(errorMessage); if (Common.isNotNull(errorMessage) && errorMessage.length() > 300) {
leave.setFailEmpTime(LocalDateTime.now()); errorMessage = errorMessage.substring(0, 300);
leave.setDoStatusEmp(CommonConstants.NINE_STRING);
} }
leave.setFailEmpRemark(errorMessage);
leave.setFailEmpTime(LocalDateTime.now());
leave.setDoStatusEmp(CommonConstants.NINE_STRING);
} }
} }
} else { }
// 全部成功 } else {
for (EmployeeRegistrationLeave leave : leaveList) { // 全部成功
if (judgeToUpdateEmp(doType, leave) ) { for (EmployeeRegistrationLeave leave : leaveList) {
leave.setEmpId(leave.getEmpIdOld()); if (judgeToUpdateEmp(doType, leave)) {
leave.setDoStatusEmp(CommonConstants.EIGHT_STRING); leave.setEmpId(leave.getEmpIdOld());
} leave.setDoStatusEmp(CommonConstants.EIGHT_STRING);
} }
} }
} }
......
...@@ -271,5 +271,26 @@ public class TInsuranceAlert extends BaseEntity { ...@@ -271,5 +271,26 @@ public class TInsuranceAlert extends BaseEntity {
@Schema(description = "新派单的商险ID") @Schema(description = "新派单的商险ID")
private String insurancesIdNew; private String insurancesIdNew;
/**
* 保单开始时间
*/
@TableField(exist = false)
@Schema(description = "保单开始时间-新")
private LocalDate policyStartNew;
/**
* 保单结束时间
*/
@TableField(exist = false)
@Schema(description = "保单结束时间-新")
private LocalDate policyEndNew;
/**
* 保单生效日期
*/
@TableField(exist = false)
@Schema(description = "保单生效日期-新")
private LocalDate policyEffectNew;
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
} }
\ No newline at end of file
...@@ -320,7 +320,7 @@ public class TInsuranceWarnServiceImpl extends ServiceImpl<TInsuranceWarnMapper, ...@@ -320,7 +320,7 @@ public class TInsuranceWarnServiceImpl extends ServiceImpl<TInsuranceWarnMapper,
detail.setPolicyEffectOld(vo.getPolicyEffect()); detail.setPolicyEffectOld(vo.getPolicyEffect());
detail.setPolicyStartOld(vo.getPolicyStart()); detail.setPolicyStartOld(vo.getPolicyStart());
detail.setPolicyEndOld(vo.getPolicyEnd()); detail.setPolicyEndOld(vo.getPolicyEnd());
detail.setBuyType(vo.getBuyType()); detail.setBuyType(CommonConstants.ONE_INT);
detail.setConfigId(vo.getConfigId()); detail.setConfigId(vo.getConfigId());
detail.setConfigName(vo.getConfigName()); detail.setConfigName(vo.getConfigName());
detail.setInsuranceCompanyName(vo.getInsuranceCompanyName()); detail.setInsuranceCompanyName(vo.getInsuranceCompanyName());
...@@ -332,14 +332,13 @@ public class TInsuranceWarnServiceImpl extends ServiceImpl<TInsuranceWarnMapper, ...@@ -332,14 +332,13 @@ public class TInsuranceWarnServiceImpl extends ServiceImpl<TInsuranceWarnMapper,
AutoDeptDetailVO detailVO = deptMap.get(vo.getDeptNo()); AutoDeptDetailVO detailVO = deptMap.get(vo.getDeptNo());
// 预计派单时间 // 预计派单时间
if (Common.isNotNull(vo.getPolicyEnd())) { if (Common.isNotNull(vo.getPolicyEnd())) {
detail.setPolicyStart(vo.getPolicyEnd().plusDays(CommonConstants.ONE_INT));
detail.setPolicyEffect(detail.getPolicyStart());
LocalDate days = calculateThreeWorkDays(vo.getPolicyEnd(), holidayMap); LocalDate days = calculateThreeWorkDays(vo.getPolicyEnd(), holidayMap);
if (days != null && Common.isNotNull(days)) { if (days != null && Common.isNotNull(days)) {
// 新增逻辑 // 新增逻辑
detail.setExpectedCollectionTime(days.atTime(15, 20)); detail.setExpectedCollectionTime(days.atTime(15, 20));
if (Common.isNotNull(vo.getPolicyStart())) {
detail.setPolicyStart(vo.getPolicyStart().plusDays(CommonConstants.ONE_INT));
}
detail.setPolicyEffect(detail.getPolicyStart());
Integer month = CommonConstants.ONE_INT; Integer month = CommonConstants.ONE_INT;
if (detailVO != null && Common.isNotNull(detailVO.getNum())) { if (detailVO != null && Common.isNotNull(detailVO.getNum())) {
month = detailVO.getNum(); month = detailVO.getNum();
......
...@@ -308,7 +308,7 @@ ...@@ -308,7 +308,7 @@
JOIN t_insurance_alert b ON b.INSURANCES_PRE_RENEW_DETAIL_ID = a.ID JOIN t_insurance_alert b ON b.INSURANCES_PRE_RENEW_DETAIL_ID = a.ID
where b.EXPIRE_IGNORE_FLAG = '1' and b.DELETE_FLAG=0 and a.is_leave = '0' and b.IS_OVERDUE = 0 where b.EXPIRE_IGNORE_FLAG = '1' and b.DELETE_FLAG=0 and a.is_leave = '0' and b.IS_OVERDUE = 0
AND a.process_status in ('0','1','2','5') AND a.process_status in ('0','1','2','5')
and DATE_FORMAT(a.expected_collection_time,"%Y-%m-%d") <![CDATA[ <= ]]> CURDATE() and DATE_FORMAT(a.expected_collection_time,"%Y-%m-%d") <![CDATA[ <= ]]> DATE_FORMAT(CURDATE(),"%Y-%m-%d")
</select> </select>
<!-- 获取所有待确认的数据 --> <!-- 获取所有待确认的数据 -->
...@@ -319,7 +319,7 @@ ...@@ -319,7 +319,7 @@
JOIN t_insurance_alert b ON b.INSURANCES_PRE_RENEW_DETAIL_ID = a.ID JOIN t_insurance_alert b ON b.INSURANCES_PRE_RENEW_DETAIL_ID = a.ID
where b.EXPIRE_IGNORE_FLAG = '1' and b.DELETE_FLAG=0 and a.is_leave = '0' and b.IS_OVERDUE = 0 where b.EXPIRE_IGNORE_FLAG = '1' and b.DELETE_FLAG=0 and a.is_leave = '0' and b.IS_OVERDUE = 0
AND a.process_status = '0' and DATE_FORMAT(a.confirm_Date,"%Y-%m-%d") <![CDATA[ <= ]]> CURDATE() AND a.process_status = '0' and DATE_FORMAT(a.confirm_Date,"%Y-%m-%d") <![CDATA[ <= ]]> CURDATE()
AND DATE_FORMAT(a.expected_collection_time,"%Y-%m-%d") >= CURDATE()
group by a.customer_user_loginname group by a.customer_user_loginname
</select> </select>
......
...@@ -56,6 +56,9 @@ ...@@ -56,6 +56,9 @@
<result property="isAddress" column="IS_ADDRESS" jdbcType="CHAR"/> <result property="isAddress" column="IS_ADDRESS" jdbcType="CHAR"/>
<result property="expectedCollectionTime" column="expected_collection_time" jdbcType="TIMESTAMP"/> <result property="expectedCollectionTime" column="expected_collection_time" jdbcType="TIMESTAMP"/>
<result property="insurancesIdNew" column="INSURANCES_ID_NEW" jdbcType="VARCHAR"/> <result property="insurancesIdNew" column="INSURANCES_ID_NEW" jdbcType="VARCHAR"/>
<result property="policyStartNew" column="POLICY_START_NEW" jdbcType="DATE"/>
<result property="policyEndNew" column="POLICY_END_NEW" jdbcType="DATE"/>
<result property="policyEffectNew" column="POLICY_EFFECT_NEW" jdbcType="DATE"/>
</resultMap> </resultMap>
<!-- 商险续签待办专用 --> <!-- 商险续签待办专用 -->
...@@ -285,7 +288,57 @@ ...@@ -285,7 +288,57 @@
<!--tInsuranceAlert简单分页查询--> <!--tInsuranceAlert简单分页查询-->
<select id="getTInsuranceAlertList2000" resultMap="BaseResultMap"> <select id="getTInsuranceAlertList2000" resultMap="BaseResultMap">
SELECT SELECT
<include refid="Alert_Column_List"/> a.ID,
a.EMP_NAME,
a.EMP_IDCARD_NO,
a.DEPT_NO,
a.POST,
b.INSURANCE_COMPANY_NAME,
b.INSURANCE_TYPE_NAME,
b.INSURANCE_CITY_NAME,
a.INSURANCE_HANDLE_CITY_NAME,
a.INSURANCE_HANDLE_PROVINCE_NAME,
b.INSURANCE_PROVINCE_NAME,
b.BUY_STANDARD,
a.UNIT_NAME,
a.UNIT_NO,
a.SETTLE_TYPE,
a.POLICY_EFFECT,
a.EXPIRE_REMARK,
a.EXPIRE_IGNORE_FLAG,
a.SETTLE_MONTH,
a.POLICY_START,
a.POLICY_END,
a.ACTUAL_PREMIUM,
a.ESTIMATE_PREMIUM,
a.INVOICE_NO,
a.MEDICAL_QUOTA,
a.DIE_DISABLE_QUOTA,
a.DEPT_NAME,
a.POLICY_NO,
a.IS_OVERDUE,
a.REMARK,
a.CREATE_BY,
a.DELETE_FLAG,
a.CREATE_NAME,
a.CREATE_TIME,
a.UPDATE_BY,
a.UPDATE_TIME,
a.CREATE_USER_DEPT_NAME,
a.IS_EFFECT,
a.ALERTER,
a.ALERT_ID,
a.HAVE_WORK_DAY,
a.INSURANCES_PRE_RENEW_DETAIL_ID,
b.BUY_TYPE,
b.process_status,
b.error_info,
b.error_time
,DATE_FORMAT(b.expected_collection_time,'%Y-%m-%d %H:%i') expected_collection_time
,b.INSURANCES_ID_NEW,
b.POLICY_EFFECT POLICY_EFFECT_NEW,
b.POLICY_START POLICY_START_NEW,
b.POLICY_END POLICY_END_NEW
FROM t_insurance_alert a FROM t_insurance_alert a
JOIN t_insurance_pre_renew_detail b ON a.INSURANCES_PRE_RENEW_DETAIL_ID = b.ID JOIN t_insurance_pre_renew_detail b ON a.INSURANCES_PRE_RENEW_DETAIL_ID = b.ID
<where> <where>
......
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