| | |
| | | if(Objects.nonNull(data1)){ |
| | | String vipJson = data1.getVipJson(); |
| | | TVip vip = JSON.parseObject(vipJson, TVip.class); |
| | | tAccountingStrategyDetailVO.setDiscount(vip.getDiscount()); |
| | | if(Objects.nonNull(vip) && vip.getType() == 2){ |
| | | tAccountingStrategyDetailVO.setDiscount(vip.getDiscount().divide(new BigDecimal(10))); |
| | | } |
| | | } |
| | | } |
| | | return tAccountingStrategyDetailVOS; |
| | | } |
| | | |
| | | @Override |
| | | public List<TAccountingStrategyDetailVO> queryMangementAccountingStrategyDetailByStrategyId(Integer strategyId) { |
| | | return this.baseMapper.queryAccountingStrategyDetailByStrategyId(strategyId); |
| | | } |
| | | |
| | | @Override |
| | |
| | | if(Objects.nonNull(vip)) { |
| | | if (vip.getType() == 2) { |
| | | accountingStrategyDetailVO.setTotalPrice(accountingStrategyDetailVO.getElectrovalence().add(accountingStrategyDetailVO.getServiceCharge().multiply(vip.getDiscount()))); |
| | | accountingStrategyDetailVO.setDiscount(vip.getDiscount()); |
| | | accountingStrategyDetailVO.setDiscount(vip.getDiscount().divide(new BigDecimal(10))); |
| | | accountingStrategyDetailNext.setTotalPrice(accountingStrategyDetailNext.getElectrovalence().add(accountingStrategyDetailNext.getServiceCharge().multiply(vip.getDiscount()))); |
| | | } else { |
| | | if(Objects.isNull(accountingStrategy.getDiscount())){ |
| | |
| | | } |
| | | // 查询最高折扣的会员 |
| | | TVip monthlyCardDiscount = vipClient.getVipInfoByType(3).getData(); |
| | | strategyPriceVO.setServiceFeeDiscount(monthlyCardDiscount.getMonthlyCardDiscount()); |
| | | strategyPriceVO.setServiceFeeDiscount(null == monthlyCardDiscount ? new BigDecimal(10) : monthlyCardDiscount.getMonthlyCardDiscount()); |
| | | // 查询最高优惠的会员 |
| | | TVip maximumDeduction = vipClient.getVipInfoByType(1).getData(); |
| | | strategyPriceVO.setMaxDiscountAmount(maximumDeduction.getMaximumDeduction()); |
| | | strategyPriceVO.setMaxDiscountAmount(null == maximumDeduction ? new BigDecimal(10) : maximumDeduction.getMaximumDeduction()); |
| | | // 查询最低起步价会员 |
| | | TVip monthlyCard = vipClient.getVipInfoByType(2).getData(); |
| | | strategyPriceVO.setVipStartPrice(monthlyCard.getMonthlyCard()); |
| | | strategyPriceVO.setVipStartPrice(null == monthlyCard ? new BigDecimal(10) : monthlyCard.getMonthlyCard()); |
| | | // 模板折扣 |
| | | strategyPriceVO.setDiscount(accountingStrategy.getDiscount()); |
| | | return strategyPriceVO; |