Skip to content

Commit 0eed2fa

Browse files
committed
没问题
1 parent 3accf80 commit 0eed2fa

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/dal/mysql/coupon

yudao-module-mall/yudao-module-promotion/src/main/java/cn/iocoder/yudao/module/promotion/dal/mysql/coupon/CouponTemplateMapper.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ static Consumer<LambdaQueryWrapper<CouponTemplateDO>> buildCanTakeQueryConsumer(
7676
.in(CouponTemplateDO::getTakeType, canTakeTypes) // 2. 领取方式一致
7777
.and(ww -> ww.gt(CouponTemplateDO::getValidEndTime, LocalDateTime.now()) // 3.1 未过期
7878
.or().eq(CouponTemplateDO::getValidityType, CouponTemplateValidityTypeEnum.TERM.getType())) // 3.2 领取之后
79-
.apply(" (take_count < total_count OR total_count = -1)"); // 4. 剩余数量大于 0,或者无限领取
79+
.apply(" (take_count < total_count OR total_count = " + CouponTemplateDO.TOTAL_COUNT_MAX + ")"); // 4. 剩余数量大于 0,或者无限领取
8080
}
8181
return canTakeConsumer;
8282
}

0 commit comments

Comments
 (0)