This commit is contained in:
aaron 2025-04-07 18:41:08 +08:00
parent 74ef2407e7
commit 787c559d46
2 changed files with 3 additions and 1 deletions

View File

@ -171,7 +171,9 @@ async def check_activity_can_receive(
CouponReceiveRecordDB.activity_id == activity_id CouponReceiveRecordDB.activity_id == activity_id
).scalar() ).scalar()
if activity.total_limit > 0 and total_receive_count >= activity.total_limit: total = total_receive_count if total_receive_count else 0
if activity.total_limit > 0 and total >= activity.total_limit:
return False, f"优惠券活动已领完", activity return False, f"优惠券活动已领完", activity
# 检查用户领取次数 # 检查用户领取次数

Binary file not shown.