积分模块相关代码
This commit is contained in:
@@ -241,10 +241,10 @@ public class TbPointsExchangeRecordServiceImpl extends ServiceImpl<TbPointsExcha
|
||||
// 设置支付方式
|
||||
entity.setPayMethod(payMethod.get(record.getPayType().toUpperCase()));
|
||||
// 纯积分支付并且商品需要额外支付金额,需要抛出异常
|
||||
if ("POINTS".equals(entity.getPayType()) && NumberUtil.isGreater(record.getExtraPaymentAmount(), BigDecimal.ZERO)) {
|
||||
if ("POINTS".equals(entity.getPayType()) && NumberUtil.isGreater(entity.getExtraPaymentAmount(), BigDecimal.ZERO)) {
|
||||
throw new MsgException("此商品需要额外支付金额");
|
||||
}
|
||||
if (!"POINTS".equals(entity.getPayType()) && NumberUtil.equals(record.getExtraPaymentAmount(), BigDecimal.ZERO)) {
|
||||
if (!"POINTS".equals(entity.getPayType()) && NumberUtil.equals(entity.getExtraPaymentAmount(), BigDecimal.ZERO)) {
|
||||
throw new MsgException("此商品不需要额外支付金额");
|
||||
}
|
||||
// 如果不需要额外支付
|
||||
|
||||
Reference in New Issue
Block a user