| | |
| | | @TableField(exist = false) |
| | | private String applyCode; |
| | | |
| | | @ApiModelProperty(value = "商户名称", example = "1") |
| | | @TableField(exist = false) |
| | | private String companyName; |
| | | |
| | | @ApiModelProperty(value = "实际保险生效止期") |
| | | @TableField(exist = false) |
| | |
| | | .selectAs(Solutions::getTimeUnit,UnionApply::getTimeUnit) |
| | | .selectAs(Solutions::getOrtherInfo,UnionApply::getOrtherInfo) |
| | | .selectAs(Solutions::getSpecialAgreement,UnionApply::getSpecialAgreement) |
| | | .selectAs(Company::getName,UnionApply::getCompanyName) |
| | | .selectAs(Solutions::getSpecialInfo,UnionApply::getSpecialInfo); |
| | | queryWrapper.select("(select count(distinct(b.MEMBER_ID)) from apply_detail b where b.isdeleted=0 and b.union_apply_id=t.id) as insureNum "); |
| | | queryWrapper.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"); |
| | |
| | | "and b.status = "+Constants.InsuranceApplyStatus.WTB_TOUBAOING.getKey()+" and a.type = 1 ) as changeApplyNum "); |
| | | } |
| | | queryWrapper.leftJoin(Solutions.class,Solutions::getId,UnionApply::getSolutionId); |
| | | queryWrapper.leftJoin(Company.class,Company::getId,UnionApply::getCompanyId); |
| | | LoginUserInfo user = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal(); |
| | | if(Constants.equalsInteger(user.getType(),Constants.TWO)){ |
| | | queryWrapper.eq(UnionApply::getCompanyId, user.getCompanyId()); |
| | |
| | | pageWrap.getModel().setIsdeleted(Constants.ZERO); |
| | | queryWrapper.selectAs(UnionApply::getCode,UnionChange::getApplyCode); |
| | | queryWrapper.selectAs(Solutions::getName,UnionChange::getSolutionsName) |
| | | .selectAs(Company::getName,UnionChange::getCompanyName) |
| | | .select("( select count(1) from apply_chagne_detail ad where t.id = ad.UNION_CHANGE_ID and ad.TYPE = 0 )",UnionChange::getAddNum) |
| | | .select("( select count(1) from apply_chagne_detail ad where t.id = ad.UNION_CHANGE_ID and ad.TYPE = 1 )",UnionChange::getDelNum) |
| | | .select("( select count(1) from apply_chagne_detail ad where t.id = ad.UNION_CHANGE_ID and ad.TYPE = 2 )",UnionChange::getChangeNum); |
| | | queryWrapper.leftJoin(UnionApply.class,UnionApply::getId,UnionChange::getUnionApplyId); |
| | | queryWrapper.leftJoin(Solutions.class,Solutions::getId,UnionApply::getSolutionId); |
| | | queryWrapper.leftJoin(Company.class,Company::getId,UnionApply::getCompanyId); |
| | | LoginUserInfo user = (LoginUserInfo) SecurityUtils.getSubject().getPrincipal(); |
| | | if(Constants.equalsInteger(user.getType(),Constants.TWO)){ |
| | | queryWrapper.eq(UnionChange::getShopId, user.getCompanyId()); |