| | |
| | | BigDecimal amount = sku.getPresentPrice().multiply(BigDecimal.valueOf(item.getCnt())); |
| | | total = total.add(amount); |
| | | } |
| | | |
| | | BigDecimal score = ObjectUtil.isEmpty(addOrderDto.getScore()) ? BigDecimal.ZERO : addOrderDto.getScore(); |
| | | if(hasTc){ |
| | | //系统设置的个人贡献点最大值 |
| | | DataDictionaryCustom starGetDic = dataDictionaryCustomMapper.selectDicDataByTypeAndCode( |
| | |
| | | if(starGet.compareTo(star) <= 0){ |
| | | throw new FebsException("无法购买套餐"); |
| | | } |
| | | BigDecimal prizeScore = mallMemberWallet.getPrizeScore(); |
| | | if(prizeScore.compareTo(score) < 0){ |
| | | throw new FebsException("积分不足"); |
| | | } |
| | | } |
| | | } |
| | | /** |
| | |
| | | DataDictionaryEnum.SCORE_CHANGE.getType(), |
| | | DataDictionaryEnum.SCORE_CHANGE.getCode() |
| | | ); |
| | | BigDecimal score = ObjectUtil.isEmpty(addOrderDto.getScore()) ? BigDecimal.ZERO : addOrderDto.getScore(); |
| | | |
| | | if(ObjectUtil.isNotEmpty(scorePercentDic)){ |
| | | //商品的现金折扣比例 |
| | | BigDecimal scorePercent = new BigDecimal(scorePercentDic.getValue()).multiply(BigDecimal.valueOf(0.01)); |