Commit 6fbabba4 authored by 李灿灿's avatar 李灿灿

商险替换接口调试

parent 62040ee2
......@@ -100,6 +100,10 @@ public class InsurancesConstants {
* 当前记录是投保中,无法替换
*/
public static final String TWO_REPLACE_IS_NOT_ALLOW = "当前记录是投保中,无法替换";
/**
* 当前记录是投保退回,无法替换
*/
public static final String FOUR_REPLACE_IS_NOT_ALLOW = "当前记录是投保退回,无法替换";
/**
* 当前记录已出险,无法替换
*/
......@@ -160,6 +164,10 @@ public class InsurancesConstants {
* 替换员工未通过实名认证
*/
public static final String REPLACE_EMP_ID_CARD_NO_NOT_FIT = "替换员工未通过实名认证";
/**
* 替换信息和被替换信息一致,无法替换
*/
public static final String REPLACE_EMP_INFO_SAME = "替换信息和被替换信息一致,无法替换";
/**
* 替换员工身份证号格式有误
*/
......
......@@ -1478,6 +1478,12 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
}
}
if (param.getEmpName().equals(param.getReplaceEmpName()) && param.getEmpIdcardNo().equals(param.getReplaceEmpIdcardNo())){
param.setErrorMessage(InsurancesConstants.REPLACE_EMP_INFO_SAME);
listResult.add(param);
continue;
}
//根据项目编码查询项目是否存在
R<SetInfoVo> setInfoByCodes = archivesDaprUtil.getSetInfoByCodes(Arrays.asList(param.getDeptNo()));
if (null != setInfoByCodes && setInfoByCodes.getCode() == CommonConstants.SUCCESS) {
......@@ -1535,6 +1541,12 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
listResult.add(param);
continue;
}
// 投保状态 投保退回 不能替换
if (detail.getBuyHandleStatus() == CommonConstants.FOUR_INT){
param.setErrorMessage(InsurancesConstants.FOUR_REPLACE_IS_NOT_ALLOW);
listResult.add(param);
continue;
}
// 投保状态 已投保 已出险 不能替换
if (detail.getBuyHandleStatus() == CommonConstants.THREE_INT
&& detail.getIsUse() == CommonConstants.ONE_INT){
......
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