新客立减修改
This commit is contained in:
@@ -55,6 +55,14 @@ public class MkConsumeDiscountServiceImpl extends ServiceImpl<MkConsumeDiscountM
|
||||
if (consumeDiscountDTO.getRandomDiscountList() == null || consumeDiscountDTO.getRandomDiscountList().isEmpty()) {
|
||||
throw new ApiNotPrintException("随机优惠金额不能为空");
|
||||
}
|
||||
}else {
|
||||
if (consumeDiscountDTO.getDiscountAmount() == null) {
|
||||
throw new ApiNotPrintException("减免金额不能为空");
|
||||
}
|
||||
|
||||
if (consumeDiscountDTO.getDiscountAmount().compareTo(BigDecimal.ZERO) <= 0) {
|
||||
throw new ApiNotPrintException("减免金额不能等于0");
|
||||
}
|
||||
}
|
||||
|
||||
MkConsumeDiscount consumeDiscount = getOne(new QueryWrapper().eq(MkConsumeDiscount::getShopId, shopId));
|
||||
|
||||
Reference in New Issue
Block a user