| | |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"未查询到保单数据"); |
| | | } |
| | | SaveUnionChangeDTO saveUnionChangeDTO = new SaveUnionChangeDTO(); |
| | | // saveUnionChangeDTO.setApplyDate(update.getApplyStartTime()); |
| | | saveUnionChangeDTO.setApplyDate(model.getValidTime()); |
| | | List<Integer> applyIds = new ArrayList<>(); |
| | | applyIds.add(model.getId()); |
| | |
| | | saveUnionChangeDTO.setApplyChange(model); |
| | | saveUnionChangeDTO.setUnionApplyId(insuranceApply.getUnionApplyId()); |
| | | saveUnionChangeDTO.setBusinessType(model.getType()); |
| | | // if(Constants.equalsInteger(model.getType(),Constants.ONE)){ |
| | | // } |
| | | if(Constants.equalsInteger(user.getType(),Constants.TWO)){ |
| | | saveUnionChangeDTO.setShopId(user.getCompanyId()); |
| | | }else{ |
| | | CompanySolution companySolution = companySolutionMapper.selectOne(new QueryWrapper<CompanySolution>().lambda().eq(CompanySolution::getSolutionId,solutions.getId()).eq(CompanySolution::getCompanyId,insuranceApply.getCompanyId()).last(" limit 1 ")); |
| | | CompanySolution companySolution = companySolutionMapper.selectOne(new QueryWrapper<CompanySolution>() |
| | | .lambda().eq(CompanySolution::getSolutionBaseId,solutions.getBaseId()) |
| | | .eq(CompanySolution::getCompanyId,insuranceApply.getCompanyId()).last(" limit 1 ")); |
| | | if(Objects.isNull(companySolution)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"未查询到企业方案信息"); |
| | | } |
| | | saveUnionChangeDTO.setShopId(companySolution.getShopId()); |
| | | |
| | | } |
| | | // if(1==1){ |
| | | // throw new BusinessException(ResponseStatus.DATA_EMPTY); |
| | | // } |
| | | |
| | | unionChangeService.merge(saveUnionChangeDTO); |
| | | } |
| | | // if(1==1){ |
| | | // throw new BusinessException(ResponseStatus.DATA_EMPTY); |
| | | // } |
| | | return 1; |
| | | |
| | | } |