|  |  |  | 
|---|
|  |  |  | for (ApplyDetail applyDetail:applyDetailList) { | 
|---|
|  |  |  | //查询人员信息是否存在相同的方案下是否存在 冲突数据 | 
|---|
|  |  |  | InsuranceApplyServiceImpl.checkStaticMemberSolution(solutions.getBaseId(), | 
|---|
|  |  |  | applyDetail.getIdcardNo(),applyDetail.getMemberName(),unionApply.getStartTime(),unionApply.getEndTime(), | 
|---|
|  |  |  | applyDetail.getMemberId(),applyDetail.getIdcardNo(),applyDetail.getMemberName(),unionApply.getStartTime(),unionApply.getEndTime(), | 
|---|
|  |  |  | applyDetailJoinMapper); | 
|---|
|  |  |  | fee =fee.add( | 
|---|
|  |  |  | Constants.reduceFee(solutions,solutions.getPrice(),applyDetail.getStartTime(),applyDetail.getEndTime(),saveUnionApplyDTO.getStartDate(),saveUnionApplyDTO.getEndDate()) | 
|---|
|  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | //查询人员信息是否存在相同的方案下是否存在 冲突数据 | 
|---|
|  |  |  | InsuranceApplyServiceImpl.checkStaticMemberSolution(solutions.getBaseId(), | 
|---|
|  |  |  | applyDetail.getIdcardNo(),applyDetail.getMemberName(),unionApply.getStartTime(),unionApply.getEndTime(), | 
|---|
|  |  |  | applyDetail.getMemberId(),applyDetail.getIdcardNo(),applyDetail.getMemberName(),unionApply.getStartTime(),unionApply.getEndTime(), | 
|---|
|  |  |  | applyDetailJoinMapper); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | applyDetail.setPrice(price); | 
|---|
|  |  |  | applyDetail.setFee(price.multiply(new BigDecimal(maxDays)).add(serverCost)); | 
|---|
|  |  |  | applyDetail.setStartTime(unionApplyBXDDTO.getStartTime()); | 
|---|
|  |  |  | applyDetail.setEndTime(unionApplyBXDDTO.getEndTime()); | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | MemberInsurance memberInsurance = new MemberInsurance(applyDetail,user.getId()); | 
|---|
|  |  |  | 
|---|
|  |  |  | ); | 
|---|
|  |  |  |  | 
|---|
|  |  |  | } | 
|---|
|  |  |  | memberInsuranceJoinMapper.insertBatchSomeColumn(memberInsuranceList); | 
|---|
|  |  |  | memberInsuranceJoinMapper.insert(memberInsuranceList); | 
|---|
|  |  |  | } | 
|---|
|  |  |  | BigDecimal detailFee = Constants.reduceFee(solutions,solutions.getPrice().add(serverCost),insuranceApply.getStartTime(),insuranceApply.getFinalEndTime(), | 
|---|
|  |  |  | unionApplyBXDDTO.getStartTime(),unionApplyBXDDTO.getEndTime()); | 
|---|
|  |  |  | 
|---|
|  |  |  | ,unionApply.getId(),applyLogType.getKey(),null, JSONObject.toJSONString(unionApply)); | 
|---|
|  |  |  | applyLogMapper.insert(log); | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | } | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|