Commit 42622ddf authored by zhaji's avatar zhaji

"feature-zhaJi:修改批增时保单号存在与否的逻辑校验"

parent 47160fe9
......@@ -60,7 +60,6 @@ public class EkpInsuranceUtil {
//wholeForm.add("formValues", new String(formValues.getBytes("UTF-8"),"ISO-8859-1"));
wholeForm.add("formValues", formValues);
//wholeForm.add("formValues", new String("{\"fd_3adfe6af71a1cc\":\"王五\", \"fd_3adfe658c6229e\":\"2019-03-26\", \"fd_3adfe6592b4158\":\"这里内容\"}".getBytes("UTF-8"),"ISO-8859-1") );
//System.out.println("wholeForm:"+wholeForm);
HttpHeaders headers = new HttpHeaders();
//如果EKP对该接口启用了Basic认证,那么客户端需要加入
//addAuth(headers,"yourAccount"+":"+"yourPassword");是VO,则使用APPLICATION_JSON
......
......@@ -2033,16 +2033,15 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
}else {
param.setInsuranceHandleCity(Integer.parseInt(redisHandleCityName));
}
//保单开始日期、结束日期,由系统根据保单号关联查询投保状态为 "已投保" 的商险记录的任意一条
TInsuranceDetail limitOne = this.baseMapper.selectOne(Wrappers.<TInsuranceDetail>query().lambda()
TInsuranceDetail limitOne = getOne(Wrappers.<TInsuranceDetail>query().lambda()
.eq(TInsuranceDetail::getPolicyNo, param.getPolicyNo())
.eq(TInsuranceDetail::getBuyHandleStatus, CommonConstants.THREE_INT)
//有效
.and(
/*.and(
wrapper -> wrapper.eq(TInsuranceDetail::getIsEffect,CommonConstants.ZERO_INT)
.or().isNull(TInsuranceDetail::getIsEffect)
)
)*/
//未过期
.and(
wrapper -> wrapper.eq(TInsuranceDetail::getIsOverdue,CommonConstants.ZERO_INT)
......@@ -3360,7 +3359,6 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
return R.failed(InsurancesConstants.SETTLE_MONTH_CHANGE_LIST_IS_EMPTY);
}
Map<String, List<SettleMonthChangeCheckParam>> map = settleMonthChangeCheck(settleMonthCheckList, user);
//todo 生成EKP通知,通知ekp变更结算月份
List<SettleMonthChangeCheckParam> successList = map.get("successList");
List<SettleMonthChangeCheckParam> errorList = map.get("errorList");
List<SettleMonthChangeCheckParam> ekpList = new ArrayList<>();
......@@ -3394,6 +3392,9 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
threadPool.execute(()->{
List<EkpInteractiveParam> deptDetail = getDeptDetail(ekpList);
for (EkpInteractiveParam ekpInteractiveParam : deptDetail) {
TInsuranceDetail byId = getById(ekpInteractiveParam.getDetailId());
BeanCopyUtils.copyProperties(byId,ekpInteractiveParam);
ekpInteractiveParam.setInteractiveType(InsurancesConstants.UPDATE_SETTLE_BILL);
String body = eKPInsuranceUtil.sendToEkp(ekpInteractiveParam);
if (!StringUtils.isBlank(body)){
TInsuranceOperate insuranceOperate = new TInsuranceOperate();
......@@ -3452,6 +3453,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
EkpInteractiveParam interactiveParam = new EkpInteractiveParam();
TInsuranceDetail one = getOne(lambdaQuery().getWrapper().eq(TInsuranceDetail::getId, success.getId()));
BeanCopyUtils.copyProperties(one,interactiveParam);
interactiveParam.setDetailId(success.getId());
LambdaUpdateWrapper<TInsuranceDetail> updateWrapper = new LambdaUpdateWrapper<>();
Integer oldSettleType = success.getOldSettleType();
Integer newSettleType = success.getNewSettleType();
......@@ -5375,7 +5377,7 @@ public class TInsuranceDetailServiceImpl extends ServiceImpl<TInsuranceDetailMap
if(null != byId.getActualPremium()){
param.setActualPremium(byId.getActualPremium().negate());
}
param.setInteractiveType(InsurancesConstants.NEW_SETTLE_BILL);
param.setInteractiveType(InsurancesConstants.CORRECT_SETTLE_BILL);
param.setSettleType(InsurancesConstants.ESTIMATE_SETTLE_BILL);
pushType = CommonConstants.FIVE_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