diff --git a/app/Service/Api/User/IndexService.php b/app/Service/Api/User/IndexService.php index 214b5b6..36b3319 100644 --- a/app/Service/Api/User/IndexService.php +++ b/app/Service/Api/User/IndexService.php @@ -52,7 +52,7 @@ class IndexService extends BaseService return $this->userCouponModel ->where('user_id',$this->userId) ->where('status',CouponCode::COUPON_STATUS_UNUSED) - ->where('validity_end_time','<',date('Y-m-d H:i:s')) + ->where('validity_end_time','>=',date('Y-m-d H:i:s')) ->count() ?? 0; } diff --git a/app/Service/Api/User/MyPageService.php b/app/Service/Api/User/MyPageService.php index 0926b0a..1e24060 100644 --- a/app/Service/Api/User/MyPageService.php +++ b/app/Service/Api/User/MyPageService.php @@ -66,7 +66,7 @@ class MyPageService extends BaseService return $this->userCouponModel ->where('user_id',$this->userId) ->where('status',CouponCode::COUPON_STATUS_UNUSED) - ->where('validity_end_time','<',date('Y-m-d H:i:s')) + ->where('validity_end_time','>=',date('Y-m-d H:i:s')) ->count() ?? 0; }