mirror of
https://github.com/v2board/v2board.git
synced 2024-11-10 17:49:11 +08:00
update
This commit is contained in:
parent
89d67279c6
commit
2a693e4911
@ -15,7 +15,7 @@ class CouponController extends Controller
|
|||||||
if (!$coupon) {
|
if (!$coupon) {
|
||||||
abort(500, '优惠券无效');
|
abort(500, '优惠券无效');
|
||||||
}
|
}
|
||||||
if ($coupon->limit_use <= 0) {
|
if ($coupon->limit_use <= 0 && $coupon->limit_use !== NULL) {
|
||||||
abort(500, '优惠券已无可用次数');
|
abort(500, '优惠券已无可用次数');
|
||||||
}
|
}
|
||||||
if (time() < $coupon->started_at) {
|
if (time() < $coupon->started_at) {
|
||||||
|
@ -79,7 +79,7 @@ class OrderController extends Controller
|
|||||||
if (!$coupon) {
|
if (!$coupon) {
|
||||||
abort(500, '优惠券无效');
|
abort(500, '优惠券无效');
|
||||||
}
|
}
|
||||||
if ($coupon->limit_use <= 0) {
|
if ($coupon->limit_use <= 0 && $coupon->limit_use !== NULL) {
|
||||||
abort(500, '优惠券已无可用次数');
|
abort(500, '优惠券已无可用次数');
|
||||||
}
|
}
|
||||||
if (time() < $coupon->started_at) {
|
if (time() < $coupon->started_at) {
|
||||||
|
Loading…
Reference in New Issue
Block a user