111
k94314517
2024-02-23 274d9de5e50cc2d23b25ba271a8e66021b448916
111
已修改12个文件
151 ■■■■ 文件已修改
server/service/src/main/java/com/doumee/biz/system/impl/SystemMenuBizImpl.java 6 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/core/utils/Constants.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/dao/business/dto/ApplyDetailPageDTO.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/dao/business/model/InsuranceApply.java 17 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/dao/business/model/MemberInsurance.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/dao/business/model/Taxes.java 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/business/impl/ApplyChagneDetailServiceImpl.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/business/impl/ApplyChangeServiceImpl.java 27 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/business/impl/CompanyServiceImpl.java 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/business/impl/DispatchUnitServiceImpl.java 49 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java 18 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/service/business/impl/TaxesServiceImpl.java 5 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
server/service/src/main/java/com/doumee/biz/system/impl/SystemMenuBizImpl.java
@@ -25,6 +25,7 @@
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;
import java.util.stream.Collectors;
@Service
public class SystemMenuBizImpl implements SystemMenuBiz {
@@ -110,8 +111,12 @@
    public List<SystemMenuListVO> findTreeByType(Integer type) {
        List<SystemMenuListVO> menus = systemMenuService.findList(type);
        List<SystemMenuListVO> rootMenus = new ArrayList<>();
        if(type.equals(Constants.ONE)){
            menus = menus.stream().filter(m->!m.getDisabled()).collect(Collectors.toList());
        }
        // 添加根菜单
        for (SystemMenu menu : menus) {
            if (menu.getParentId() == null) {
                SystemMenuListVO rootMenu = new SystemMenuListVO();
                BeanUtils.copyProperties(menu, rootMenu, "children");
@@ -147,6 +152,7 @@
                SystemMenu systemMenu = new SystemMenu();
                systemMenu.setType(type);
                systemMenu.setDeleted(Boolean.FALSE);
                systemMenu.setDisabled(Boolean.FALSE);
                menus = systemMenuService.findList(systemMenu);
            }
        }
server/service/src/main/java/com/doumee/core/utils/Constants.java
@@ -855,7 +855,7 @@
        COMPANY_BACK_APPLY_WAIT_SIGNATURE(7, "企业申请退回(待签章)","提交意见:${param}",5),
        COMPANY_BACK_APPLY_SIGNATURE(8, "企业申请退回(已签章)","提交意见:${param}",5),
        CLOSE(9, "订单关闭","",6),
        PLATFORM_CHECK_PASS(10,"平台投保审核通过","提交意见:${param}",1),
        PLATFORM_CHECK_PASS(10,"平台投保审核通过","提交意见:${param}",0),
        ;
        // 成员变量
        private String name;
server/service/src/main/java/com/doumee/dao/business/dto/ApplyDetailPageDTO.java
@@ -49,7 +49,7 @@
    @ApiModelProperty(value = "保单主键")
    private Integer applyId;
    @ApiModelProperty(value = "加减保主键")
    private Integer applyChangId;
    private Integer applyChangeId;
    @ApiModelProperty(value = "类型:0=加保;1=减保;2=换厂 ")
    private List<Integer> types;
server/service/src/main/java/com/doumee/dao/business/model/InsuranceApply.java
@@ -191,6 +191,23 @@
    private Date lastChangeDate;
    @ApiModelProperty(value = "最低年龄", example = "1")
    @TableField(exist = false)
    private Integer minAge;
    @ApiModelProperty(value = "最高年龄", example = "1")
    @TableField(exist = false)
    private Integer maxAge;
    @ApiModelProperty(value = "保险费用(人/天)", example = "1")
    @TableField(exist = false)
    private BigDecimal price;
    @ApiModelProperty(value = "保险时间单位0天 1半月 2月 3年", example = "1")
    @TableField(exist = false)
    private Integer timeUnit;
    public TaxesInvoicingVO toTaxesInvoicingVO(){
        TaxesInvoicingVO taxesInvoicingVO = new TaxesInvoicingVO();
        taxesInvoicingVO.setId(this.getId());
server/service/src/main/java/com/doumee/dao/business/model/MemberInsurance.java
@@ -170,11 +170,12 @@
    @TableField(exist = false)
    private Integer sn;
    @ApiModelProperty(value = "关联明细主键", example = "1")
    private Integer relationId;
    @ApiModelProperty(value = "关联类型:0=投保申请;1=加减保/换厂", example = "1")
    private Integer relationType;
    @ApiModelProperty(value = "员工名称", example = "1")
    @TableField(exist = false)
    private String memberName;
server/service/src/main/java/com/doumee/dao/business/model/Taxes.java
@@ -180,12 +180,17 @@
    @TableField(exist = false)
    private Integer applyId;
    @ApiModelProperty(value = "撤回操作人")
    @TableField(exist = false)
    private String cancelUserName;
    public TaxesInvoicingVO getTaxesInvoicingVO(){
        TaxesInvoicingVO taxesInvoicingVO = new TaxesInvoicingVO();
        taxesInvoicingVO.setId(this.getId());
        taxesInvoicingVO.setSolutionsName(this.getSolutionName());
        taxesInvoicingVO.setInsuranceCode(this.getInsuranceCode());
        taxesInvoicingVO.setDownCode(this.getDoneCode());
        taxesInvoicingVO.setCreateTime(this.getCreateDate());
        taxesInvoicingVO.setAmount(this.getPrice());
        taxesInvoicingVO.setType(Constants.TWO);
        return taxesInvoicingVO;
server/service/src/main/java/com/doumee/service/business/impl/ApplyChagneDetailServiceImpl.java
@@ -214,7 +214,7 @@
                ApplyChagneDetail::getEndTime, DateUtil.getDate(new Date(),"yyyy-MM-dd")+" 23:59:59");
        queryWrapper.eq(!Objects.isNull(applyDetailPageDTO.getDuId()),ApplyChagneDetail::getDuId,applyDetailPageDTO.getDuId());
        queryWrapper.eq(!Objects.isNull(applyDetailPageDTO.getWorkTypeId()),ApplyChagneDetail::getWorktypeId,applyDetailPageDTO.getWorkTypeId());
        queryWrapper.eq(!Objects.isNull(applyDetailPageDTO.getApplyChangId()),ApplyChagneDetail::getApplyChangeId,applyDetailPageDTO.getApplyChangId());
        queryWrapper.eq(!Objects.isNull(applyDetailPageDTO.getApplyChangeId()),ApplyChagneDetail::getApplyChangeId,applyDetailPageDTO.getApplyChangeId());
        queryWrapper.like(StringUtils.isNotBlank(applyDetailPageDTO.getMemberName()),Member::getName,applyDetailPageDTO.getMemberName());
        queryWrapper.ge(StringUtils.isNotBlank(applyDetailPageDTO.getStartTimeS()),ApplyChagneDetail::getStartTime,applyDetailPageDTO.getStartTimeS()+" 00:00:00");
        queryWrapper.le(StringUtils.isNotBlank(applyDetailPageDTO.getStartTimeE()),ApplyChagneDetail::getStartTime,applyDetailPageDTO.getStartTimeE()+" 23:59:59");
@@ -251,7 +251,7 @@
        queryWrapper.leftJoin(Worktype.class,Worktype::getId,ApplyChagneDetail::getOldWorktypeId);
        queryWrapper.leftJoin(DispatchUnit.class,DispatchUnit::getId,ApplyChagneDetail::getOldDuId);
        queryWrapper.in(CollectionUtils.isNotEmpty(applyDetailPageDTO.getTypes()),ApplyChagneDetail::getType,applyDetailPageDTO.getTypes());
        queryWrapper.eq(!Objects.isNull(applyDetailPageDTO.getApplyChangId()),ApplyChagneDetail::getApplyChangeId,applyDetailPageDTO.getApplyChangId());
        queryWrapper.eq(!Objects.isNull(applyDetailPageDTO.getApplyChangeId()),ApplyChagneDetail::getApplyChangeId,applyDetailPageDTO.getApplyChangeId());
        return applyChangeDetailJoinMapper.selectJoinList(ApplyChagneDetail.class, queryWrapper);
    }
server/service/src/main/java/com/doumee/service/business/impl/ApplyChangeServiceImpl.java
@@ -123,6 +123,7 @@
            throw  new BusinessException(ResponseStatus.DATA_EMPTY);
        }
        if(Constants.equalsInteger(model.getStatus(),Constants.ApplyChangeStatus.UPLOAD.getKey())
                ||Constants.equalsInteger(model.getStatus(),Constants.ApplyChangeStatus.SIGNATURE.getKey())
                ||Constants.equalsInteger(model.getStatus(),Constants.ApplyChangeStatus.APPROVE.getKey())){
            //已提交和已完成状态不支持审核不通过
            throw  new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"对不起,该申请状态已流转,当前不支持该操作~");
@@ -255,6 +256,15 @@
        update.setId(model.getId());
        update.setValidCode(param.getValidCode());
        applyChangeMapper.updateById(update);
        //修改员工保单记录
        memberInsuranceJoinMapper.update(null,new UpdateWrapper<MemberInsurance>()
                .lambda()
                .set(MemberInsurance::getPdCode,param.getValidCode())
                .eq(MemberInsurance::getRelationType,Constants.ONE)
                .eq(MemberInsurance::getApplyChangeId,model.getId())
        );
        //删除原有的保单信息
        multifileMapper.delete(new UpdateWrapper<Multifile>().lambda()
                .set(Multifile::getIsdeleted,Constants.ZERO)
@@ -387,6 +397,7 @@
                applyDetailJoinMapper.insert(applyDetail);
                MemberInsurance memberInsurance = new MemberInsurance(applyDetail,update.getId());
                memberInsurance.setRelationType(Constants.ONE);
                memberInsuranceJoinMapper.insert(memberInsurance);
            }else{
@@ -481,7 +492,7 @@
                        .eq(ApplyDetail::getApplyId,update.getApplyId())
                        .eq(ApplyDetail::getIdcardNo,detail.getIdcardNo())
                        .le(ApplyDetail::getStartTime,DateUtil.getMontageDate(update.getApplyStartTime(),1))
                        .ge(ApplyDetail::getEndTime,DateUtil.getMontageDate(update.getApplyStartTime(),3))
                        .ge(ApplyDetail::getEndTime,DateUtil.getMontageDate(detail.getEndTime(),2))
                )>Constants.ZERO){
                    throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(), "当前保单下,加保人员【" + detail.getMemberName() + "】存在日期冲突的数据");
                }
@@ -521,6 +532,7 @@
                currentFee = currentFee.add(add.getCurrentFee());
                MemberInsurance memberInsurance = new MemberInsurance(detail, update, update.getEditor(), add.getId());
                memberInsurance.setRelationType(Constants.ONE);
                memberInsuranceList.add(memberInsurance);
                applyChangeDetailJoinMapper.update(null,new UpdateWrapper<ApplyChagneDetail>().lambda()
@@ -644,7 +656,9 @@
        Constants.NoticeType noticeType = Constants.NoticeType.FOUR;
        if(param.getDealBackApply() ==1){
            //如果是驳回,只能可驳回已签章状态下的退回申请状态进行操作
            if(!Constants.equalsInteger(model.getStatus(),Constants.ApplyChangeStatus.RETURN_APPLY_SIGNATURE.getKey())){
            if(!(Constants.equalsInteger(model.getStatus(),Constants.ApplyChangeStatus.RETURN_APPLY_SIGNATURE.getKey())
                    ||Constants.equalsInteger(model.getStatus(),Constants.ApplyChangeStatus.RETURN_APPLY_UPLOAD.getKey()))
            ){
                throw  new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"对不起,该申请状态已流转,当前不支持该操作~");
            }
            applyLogType = Constants.ApplyLogType.CA_PALTFORM_REFUSE_APPLY;
@@ -723,7 +737,7 @@
        }
        CompanySolution companySolution = companySolutionMapper.selectOne(new QueryWrapper<CompanySolution>().lambda()
                .eq(CompanySolution::getCompanyId,loginUserInfo.getCompanyId())
                .eq(CompanySolution::getSolutionId,solutions.getId())
                .eq(CompanySolution::getSolutionBaseId,solutions.getBaseId())
                .eq(CompanySolution::getIsdeleted,Constants.ZERO)
                .last(" limit 1 ")
        );
@@ -871,7 +885,7 @@
                .eq(DispatchUnit::getUnitStatus,Constants.ONE)
                .eq(DuSolution::getIsdeleted,Constants.ZERO)
                .eq(DuSolution::getStatus,Constants.ONE)
                .eq(DuSolution::getSolutionId,insuranceApply.getSolutionId()));
                .eq(DuSolution::getSolutionId,companySolution.getSolutionId()));
        if(!CollectionUtils.isNotEmpty(duSolutionList)){
            throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"数据异常:保险方案下未查询到派遣单位");
        }
@@ -1044,7 +1058,8 @@
                    .eq(ApplyDetail::getApplyId,applyChange.getApplyId())
                    .eq(ApplyDetail::getIdcardNo,applyChagneDetail.getIdcardNo())
                    .le(ApplyDetail::getStartTime,DateUtil.getMontageDate(applyChange.getApplyStartTime(),1))
                    .ge(ApplyDetail::getEndTime,DateUtil.getMontageDate(applyChange.getApplyStartTime(),3))
                            .ge(ApplyDetail::getEndTime,DateUtil.getMontageDate(insuranceApply.getEndTime(),2))
                    //.ge(ApplyDetail::getEndTime,DateUtil.getMontageDate(applyChange.getApplyStartTime(),3))
            )>Constants.ZERO){
                throw new BusinessException(ResponseStatus.BAD_REQUEST.getCode(), "当前保单下,加保人员【" + applyChagneDetail.getMemberName() + "】存在日期冲突的数据");
            }
@@ -1781,7 +1796,7 @@
        BigDecimal sumPrice = countCyclePriceVO.getCyclePrice();
        CountCyclePriceVO returnCountCyclePriceVO = new CountCyclePriceVO();
        //加减保金额
        returnCountCyclePriceVO.setCyclePrice(sumPrice.divide(new BigDecimal(sumDays),2, RoundingMode.HALF_UP).multiply(new BigDecimal(optDays)));
        returnCountCyclePriceVO.setCyclePrice(sumPrice.multiply(new BigDecimal(optDays)).divide(new BigDecimal(sumDays),2, RoundingMode.HALF_UP));
        return returnCountCyclePriceVO;
    }
server/service/src/main/java/com/doumee/service/business/impl/CompanyServiceImpl.java
@@ -227,15 +227,18 @@
        List<CompanySolution> list = new ArrayList<>();
        int num =0;
        for(CompanySolution s :company.getSolutionList()){
            if(s.getSolutionBaseId() == null){
            if(Objects.isNull(s.getSolution())){
                continue;
            }
            Solutions newVersion = solutionsMapper.selectOne(new QueryWrapper<Solutions>().lambda().eq(Solutions::getBaseId,s.getSolutionBaseId())
            if(s.getSolution().getBaseId() == null){
                continue;
            }
            Solutions newVersion = solutionsMapper.selectOne(new QueryWrapper<Solutions>().lambda().eq(Solutions::getBaseId,s.getSolution().getBaseId())
                    .eq(Solutions::getDataType,Constants.TWO).last("limit 1"));
            if(Objects.isNull(newVersion)){
                throw  new BusinessException(ResponseStatus.BAD_REQUEST.getCode(),"请添加有效的保险方案信息!");
            }
            sIds.add(s.getSolutionBaseId());
            sIds.add(s.getSolution().getBaseId());
            s.setCompanyId(company.getId());
            s.setIsdeleted(Constants.ZERO);
            s.setCanAdd(Constants.formatIntegerNum(s.getCanAdd()));
@@ -243,7 +246,7 @@
            s.setCreateDate(company.getCreateDate());
            s.setCreator(company.getCreator());
            s.setSortnum(num++);
            s.setSolutionBaseId( s.getSolutionBaseId() );
            s.setSolutionBaseId( s.getSolution().getBaseId() );
            s.setSolutionId( newVersion.getId() );
            s.setStatus(Constants.ZERO);
            list.add(s);
server/service/src/main/java/com/doumee/service/business/impl/DispatchUnitServiceImpl.java
@@ -102,7 +102,7 @@
        dispatchUnitMapper.updateById(update);
        if(Constants.equalsInteger(param.getWorktypeStatus(),Constants.ONE)){
            //审核通过,修改状态,产生历史版本
            newVersionData(dispatchUnitMapper.selectById(param.getId()),update);
            newVersionData(dispatchUnitMapper.selectById(param.getId()),update,false);
            //存储操作历史
            this.saveDuLog(update,Constants.DispatchUnitLogType.WORK_TYPE_AUDIT_PASS,update.getCheckInfo());
@@ -136,23 +136,32 @@
        return  1;
    }
    private void newVersionData(DispatchUnit model, DispatchUnit update) {
        dispatchUnitMapper.update(null,new UpdateWrapper<DispatchUnit>().lambda()
                .set(DispatchUnit::getDataType,Constants.ZERO)
                .eq(DispatchUnit::getIsdeleted,Constants.ZERO)
                .eq(DispatchUnit::getBaseId,model.getId()));
    private void newVersionData(DispatchUnit model, DispatchUnit update,Boolean flag) {
        DispatchUnit newVersion = new DispatchUnit();
        BeanUtils.copyProperties(model, newVersion);
        newVersion.setWorktypeStatus(Constants.ONE);
        newVersion.setCheckDate(update.getEditDate());
        newVersion.setCheckUserId(update.getCheckUserId());
        newVersion.setCheckInfo(update.getCheckInfo());
        newVersion.setCreateDate(update.getCreateDate());
        newVersion.setCreator(update.getEditor());
        newVersion.setBaseId(model.getBaseId());
        newVersion.setDataType(Constants.TWO);
        dispatchUnitMapper.insert(newVersion);
        if(flag){
            dispatchUnitMapper.update(null,new UpdateWrapper<DispatchUnit>().lambda()
                    .set(DispatchUnit::getDataType,Constants.ZERO)
                    .eq(DispatchUnit::getIsdeleted,Constants.ZERO)
                    .eq(DispatchUnit::getBaseId,model.getId()));
            BeanUtils.copyProperties(model, newVersion);
            newVersion.setWorktypeStatus(Constants.ONE);
            newVersion.setCheckDate(update.getEditDate());
            newVersion.setCheckUserId(update.getCheckUserId());
            newVersion.setCheckInfo(update.getCheckInfo());
            newVersion.setCreateDate(update.getCreateDate());
            newVersion.setCreator(update.getEditor());
            newVersion.setBaseId(model.getId());
            newVersion.setDataType(Constants.TWO);
            dispatchUnitMapper.insert(newVersion);
        }else{
            newVersion = dispatchUnitMapper.selectOne(new QueryWrapper<DispatchUnit>().lambda()
                    .eq(DispatchUnit::getIsdeleted,Constants.ZERO)
                    .eq(DispatchUnit::getDataType,Constants.TWO)
                    .eq(DispatchUnit::getBaseId,model.getId()).last(" limit 1"));
        }
        if(Objects.isNull(newVersion)){
            throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"未查询到派遣单位最新版本");
        }
        List<DuWorktype> newWorktypes = new ArrayList<>();
        List<DuSolution> solutions = duSolutionMapper.selectList(new QueryWrapper<DuSolution>().lambda()
                .eq(DuSolution::getIsdeleted,Constants.ZERO)
@@ -167,7 +176,6 @@
                .eq(DuSolution::getStatus,Constants.ZERO)
                .eq(DuSolution::getDispatchUnitId,model.getId())
        );
        if(solutions == null || solutions.size() ==0){
@@ -247,7 +255,7 @@
        DispatchUnit dispatchUnit = dispatchUnitMapper.selectById(param.getId());
        if(Constants.equalsInteger(param.getUnitStatus(),Constants.ONE)){
            //审核通过,修改状态,产生历史版本
            newVersionData(dispatchUnit,update);
            newVersionData(dispatchUnit,update,true);
            //存储操作历史
            this.saveDuLog(dispatchUnit,Constants.DispatchUnitLogType.AUDIT_PASS,update.getCheckInfo());
        }else{
@@ -455,6 +463,9 @@
        }
        LoginUserInfo loginUserInfo = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal();
        DispatchUnit dispatchUnit = this.dispatchUnitMapper.selectById(saveDispatchUnitDTO.getId());
        if(!dispatchUnit.getUnitStatus().equals(Constants.ONE)){
            throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"派遣单位未审批通过,无法进行该操作");
        }
        dispatchUnit.setWorktypeStatus(Constants.ZERO);
        dispatchUnit.setEditDate(new Date());
        dispatchUnit.setEditor(loginUserInfo.getId());
server/service/src/main/java/com/doumee/service/business/impl/InsuranceApplyServiceImpl.java
@@ -244,6 +244,7 @@
            List<MemberInsurance> memberInsuranceList = new ArrayList<>();
            for (ApplyDetail applyDetail:applyDetailList) {
                MemberInsurance memberInsurance = new MemberInsurance(applyDetail,user.getId());
                memberInsurance.setRelationType(Constants.ZERO);
                memberInsuranceList.add(memberInsurance);
            }
            memberInsuranceJoinMapper.insertBatchSomeColumn(memberInsuranceList);
@@ -282,6 +283,13 @@
        update.setId(model.getId());
        update.setCode(param.getCode());
        insuranceApplyMapper.updateById(update);
        //修改员工保单记录
        memberInsuranceJoinMapper.update(null,new UpdateWrapper<MemberInsurance>()
                        .lambda()
                .set(MemberInsurance::getBdCode,param.getCode())
                .eq(MemberInsurance::getApplyId,model.getId())
        );
        //删除原有的保单信息
        multifileMapper.delete(new UpdateWrapper<Multifile>().lambda()
                .set(Multifile::getIsdeleted,Constants.ZERO)
@@ -739,7 +747,7 @@
    @Override
    @Transactional(rollbackFor = {Exception.class,BusinessException.class})
    public Integer check(InsuranceApply insuranceApply) {
        if(insuranceApply.getId() == null || StringUtils.isBlank(insuranceApply.getCheckInfo())){
        if(insuranceApply.getId() == null){
            throw  new BusinessException(ResponseStatus.BAD_REQUEST);
        }
        InsuranceApply model = insuranceApplyMapper.selectById(insuranceApply.getId());
@@ -1138,6 +1146,10 @@
        queryWrapper.selectAll(InsuranceApply.class);
        queryWrapper.selectAs(Company::getName,InsuranceApply::getCompanyName);
        queryWrapper.selectAs(Solutions::getName,InsuranceApply::getSolutionsName);
        queryWrapper.selectAs(Solutions::getMaxAge,InsuranceApply::getMaxAge);
        queryWrapper.selectAs(Solutions::getMinAge,InsuranceApply::getMinAge);
        queryWrapper.selectAs(Solutions::getPrice,InsuranceApply::getPrice);
        queryWrapper.selectAs(Solutions::getTimeUnit,InsuranceApply::getTimeUnit);
        queryWrapper.select(" DATEDIFF( t.END_TIME ,now()  ) AS loseEfficacyDays  ");
        queryWrapper.select(" ( select count(DISTINCT(ad.MEMBER_ID)) from apply_detail ad  where ad.apply_id = t.id ) as insureNum");
        if(!Objects.isNull(pageWrap.getModel())&&!Objects.isNull(pageWrap.getModel().getType())){
@@ -1303,6 +1315,10 @@
        MPJLambdaWrapper wrapper=  new MPJLambdaWrapper<InsuranceApply>()
                .selectAll(InsuranceApply.class)
                 .selectAs(Solutions::getMaxAge,InsuranceApply::getMaxAge)
                 .selectAs(Solutions::getMinAge,InsuranceApply::getMinAge)
                .selectAs(Solutions::getPrice,InsuranceApply::getPrice)
                .selectAs(Solutions::getTimeUnit,InsuranceApply::getTimeUnit)
                .selectAs(Solutions::getName,InsuranceApply::getSolutionsName)
                .selectAs(Company::getName,InsuranceApply::getCompanyName)
                .select(" ( select max(ac.APPLY_START_TIME) from apply_change ac  where ac.apply_id = t.id and ac.status = 2 ) as lastChangeDate")
server/service/src/main/java/com/doumee/service/business/impl/TaxesServiceImpl.java
@@ -235,7 +235,9 @@
        MPJLambdaWrapper<Taxes> queryWrapper = new MPJLambdaWrapper<>();
        queryWrapper.selectAll(Taxes.class);
        queryWrapper.selectAs(Solutions::getName,Taxes::getSolutionName);
        queryWrapper.selectAs(SystemUser::getRealname,Taxes::getCancelUserName);
        queryWrapper.leftJoin(Solutions.class,Solutions::getId,Taxes::getSolutionId);
        queryWrapper.leftJoin(SystemUser.class,SystemUser::getId,Taxes::getCancelUserId);
        Taxes model =taxesJoinMapper.selectById(id);
        if(model==null || !Constants.equalsInteger(model.getIsdeleted(),Constants.ZERO)){
            throw  new BusinessException(ResponseStatus.DATA_EMPTY);
@@ -648,7 +650,7 @@
            taxDetial.setTaxId(taxes.getId());
            taxDetial.setTotalFee(taxesInvoicingVO.getAmount());
            taxDetial.setFee(taxesInvoicingVO.getAmount());
            taxDetial.setInsuranceApplyId(taxes.getApplyId());
            taxDetial.setInsuranceApplyId(taxes.getInsuranceApplyId());
            if(taxesInvoicingVO.getType().equals(Constants.ZERO)){
                taxDetial.setType(taxesInvoicingVO.getType());
            }else if(taxesInvoicingVO.getType().equals(Constants.ONE)){
@@ -675,6 +677,7 @@
                taxDetial.setTotalFee(chTaxes.getPrice());
                taxDetial.setFee(chTaxes.getPrice());
                taxDetial.setDelTaxId(chTaxes.getId());
                taxDetial.setInsuranceApplyId(taxes.getInsuranceApplyId());
                taxDetial.setType(Constants.TWO);
                taxDetailList.add(taxDetial);
            }