Commit 98197959 authored by huyuchen's avatar huyuchen

huych-入职登记商险待办提交

parent 5c644f95
...@@ -277,7 +277,7 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi ...@@ -277,7 +277,7 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
if (null != oldList && !oldList.isEmpty()) { if (null != oldList && !oldList.isEmpty()) {
for (TEmployeeInsurancePre oldInsurance : oldList) { for (TEmployeeInsurancePre oldInsurance : oldList) {
// 1:判断是否变更 商险待办 的项目 // 1:判断是否变更 商险待办 的项目
if (null != map.get(this.getFiveKey(oldInsurance))) { if (null != map.get(this.getPreOldFiveKey(oldInsurance))) {
oldMap.put(oldInsurance.getId(), oldInsurance); oldMap.put(oldInsurance.getId(), oldInsurance);
} }
} }
...@@ -744,7 +744,17 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi ...@@ -744,7 +744,17 @@ public class EmployeeRegistrationPreServiceImpl extends ServiceImpl<EmployeeRegi
return isNullToEmpty(insurancePreVo.getBuyStandard()) + CommonConstants.DOWN_LINE_STRING return isNullToEmpty(insurancePreVo.getBuyStandard()) + CommonConstants.DOWN_LINE_STRING
+ isNullToEmpty(insurancePreVo.getInsuranceTypeName()) + CommonConstants.DOWN_LINE_STRING + isNullToEmpty(insurancePreVo.getInsuranceTypeName()) + CommonConstants.DOWN_LINE_STRING
+ isNullToEmpty(insurancePreVo.getInsuranceCompanyName()) + CommonConstants.DOWN_LINE_STRING + isNullToEmpty(insurancePreVo.getInsuranceCompanyName()) + CommonConstants.DOWN_LINE_STRING
+ isNullToEmpty(insurancePreVo.getPolicyStart()) + CommonConstants.DOWN_LINE_STRING + isNullToEmpty(insurancePreVo.getPolicyEnd()); + isNullToEmpty(DateUtil.dateToString(insurancePreVo.getPolicyStart(), DateUtil.ISO_EXPANDED_DATE_FORMAT))
+ DateUtil.dateToString(insurancePreVo.getPolicyEnd(), DateUtil.ISO_EXPANDED_DATE_FORMAT);
}
private String getPreOldFiveKey(TEmployeeInsurancePre insurancePreVo) {
// 1:重复性判断
return isNullToEmpty(insurancePreVo.getBuyStandard()) + CommonConstants.DOWN_LINE_STRING
+ isNullToEmpty(insurancePreVo.getInsuranceTypeName()) + CommonConstants.DOWN_LINE_STRING
+ isNullToEmpty(insurancePreVo.getInsuranceCompanyName()) + CommonConstants.DOWN_LINE_STRING
+ isNullToEmpty(DateUtil.dateToString(insurancePreVo.getPolicyStart(), DateUtil.ISO_EXPANDED_DATE_FORMAT))
+ DateUtil.dateToString(insurancePreVo.getPolicyEnd(), DateUtil.ISO_EXPANDED_DATE_FORMAT);
} }
/** /**
......
...@@ -569,8 +569,8 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr ...@@ -569,8 +569,8 @@ public class EmployeeRegistrationServiceImpl extends ServiceImpl<EmployeeRegistr
} else { } else {
return R.other(CommonConstants.TWO_INT,null,"保险公司、险种、购买标准、保单起/止日期不可同时重复!"); return R.other(CommonConstants.TWO_INT,null,"保险公司、险种、购买标准、保单起/止日期不可同时重复!");
} }
insurancePreVo.setEmpIdcard(preVo.getEmpIdcard()); insurancePreVo.setEmpIdcard(registration.getEmpIdcard());
insurancePreVo.setDeptNo(preVo.getDeptNo()); insurancePreVo.setDeptNo(registration.getDeptNo());
//商险是否存在判断 //商险是否存在判断
checkVo = checkInsuranceExit(insurancePreVo,preVo.getEmployeeName(),preVo.getEmpIdcard()); checkVo = checkInsuranceExit(insurancePreVo,preVo.getEmployeeName(),preVo.getEmpIdcard());
if (null != checkVo) { if (null != checkVo) {
......
...@@ -376,14 +376,19 @@ public class TEmployeeInsurancePreServiceImpl extends ServiceImpl<TEmployeeInsur ...@@ -376,14 +376,19 @@ public class TEmployeeInsurancePreServiceImpl extends ServiceImpl<TEmployeeInsur
@Override @Override
public TEmployeeInsuranceSelectVo selectInsurancePreInfoList(TEmployeeInsurancePreVo preVo) { public TEmployeeInsuranceSelectVo selectInsurancePreInfoList(TEmployeeInsurancePreVo preVo) {
TEmployeeInsuranceSelectVo selectVo = new TEmployeeInsuranceSelectVo(); TEmployeeInsuranceSelectVo selectVo = new TEmployeeInsuranceSelectVo();
List<TEmployeeInsurancePre> list = baseMapper.selectList(Wrappers.<TEmployeeInsurancePre>query().lambda() List<TEmployeeInsurancePre> list = new ArrayList<>();
try {
list = baseMapper.selectList(Wrappers.<TEmployeeInsurancePre>query().lambda()
.eq(TEmployeeInsurancePre::getEmpIdcard, preVo.getEmpIdcard()) .eq(TEmployeeInsurancePre::getEmpIdcard, preVo.getEmpIdcard())
.eq(TEmployeeInsurancePre::getBuyStandard, preVo.getBuyStandard()) .eq(TEmployeeInsurancePre::getBuyStandard, preVo.getBuyStandard())
.eq(TEmployeeInsurancePre::getInsuranceTypeName, preVo.getInsuranceTypeName()) .eq(TEmployeeInsurancePre::getInsuranceTypeName, preVo.getInsuranceTypeName())
.eq(TEmployeeInsurancePre::getInsuranceCompanyName, preVo.getInsuranceCompanyName()) .eq(TEmployeeInsurancePre::getInsuranceCompanyName, preVo.getInsuranceCompanyName())
.eq(TEmployeeInsurancePre::getPolicyStart, preVo.getPolicyStart()) .eq(TEmployeeInsurancePre::getPolicyStart, DateUtil.parseDate(DateUtil.dateToString(preVo.getPolicyStart()), DateUtil.ISO_EXPANDED_DATE_FORMAT))
.eq(TEmployeeInsurancePre::getPolicyEnd, preVo.getPolicyEnd()) .eq(TEmployeeInsurancePre::getPolicyEnd, DateUtil.parseDate(DateUtil.dateToString(preVo.getPolicyEnd()), DateUtil.ISO_EXPANDED_DATE_FORMAT))
); );
}catch (Exception e){
log.error("执行异常" ,e);
}
selectVo.setInsurancePreList(list); selectVo.setInsurancePreList(list);
return selectVo; return selectVo;
} }
......
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