jiangping
2024-06-21 69c2b50ded530c6bc003c6ddbeaca786d7823270
server/service/src/main/java/com/doumee/service/business/impl/UnionApplyServiceImpl.java
@@ -333,6 +333,7 @@
                new MPJLambdaWrapper<UnionApply>()
                        .selectAll(UnionApply.class)
                        .selectAs(Solutions::getName,UnionApply::getSolutionName)
                        .selectAs(Solutions::getDelOnlyReplace,UnionApply::getDelOnlyReplace)
                        .selectAs(Company::getName,UnionApply::getCompanyName)
                        .select(" ( select count(DISTINCT(ad.MEMBER_ID)) from apply_detail ad  where ad.UNION_APPLY_ID = t.id ) as insureNum")
                .select(" ( select count(DISTINCT(b.MEMBER_ID)) from apply_detail b inner join insurance_apply a on b.apply_id = a.id  and a.status in ( 5 , 27 )  where b.union_apply_id=t.id and b.END_TIME > now() ) as guaranteeNum")
@@ -490,7 +491,7 @@
        BigDecimal fee = BigDecimal.ZERO;
        for (ApplyDetail applyDetail:applyDetailList) {
            //查询人员信息是否存在相同的方案下是否存在 冲突数据
            InsuranceApplyServiceImpl.checkStaticMemberSolution(solutions.getId(),
            InsuranceApplyServiceImpl.checkStaticMemberSolution(solutions.getBaseId(),
                    applyDetail.getIdcardNo(),applyDetail.getMemberName(),unionApply.getStartTime(),unionApply.getEndTime(),
                    applyDetailJoinMapper);
@@ -880,7 +881,7 @@
                        .filter(m->Constants.equalsInteger(m.getApplyId(),(insuranceApply.getId()))).collect(Collectors.toList())) {
                    //查询人员信息是否存在相同的方案下是否存在 冲突数据
                    InsuranceApplyServiceImpl.checkStaticMemberSolution(solutions.getId(),
                    InsuranceApplyServiceImpl.checkStaticMemberSolution(solutions.getBaseId(),
                            applyDetail.getIdcardNo(),applyDetail.getMemberName(),unionApply.getStartTime(),unionApply.getEndTime(),
                            applyDetailJoinMapper);
@@ -888,6 +889,10 @@
                    applyDetail.setFee(price.multiply(new BigDecimal(maxDays)).add(serverCost));
                    applyDetail.setStartTime(unionApplyBXDDTO.getStartTime());
                    applyDetail.setEndTime(unionApplyBXDDTO.getEndTime());
                    MemberInsurance memberInsurance = new MemberInsurance(applyDetail,user.getId());
                    memberInsurance.setBdCode(unionApplyBXDDTO.getCode());
                    memberInsurance.setRelationType(Constants.ZERO);