diff --git a/app/Services/APIs/CustomerAPIs/RestaurantApiServices.php b/app/Services/APIs/CustomerAPIs/RestaurantApiServices.php index 7efbfbc..42e2129 100644 --- a/app/Services/APIs/CustomerAPIs/RestaurantApiServices.php +++ b/app/Services/APIs/CustomerAPIs/RestaurantApiServices.php @@ -252,6 +252,7 @@ class RestaurantApiServices // Count the redeems within the state interval $redeemCountState = RedeemRestaurant::where('state_xid', $restaurant->state_xid) + ->where('iam_principal_xid', $customerIamId) ->count(); if ($redeemCountState >= $stateMaxLimitation) { @@ -263,6 +264,7 @@ class RestaurantApiServices // Count the redeems within the restaurant interval $redeemCountRestaurant = RedeemRestaurant::where('manage_restaurants_xid', $restaurant->id) + ->where('iam_principal_xid', $customerIamId) ->count(); if ($redeemCountRestaurant >= $restaurantMaxLimitation) {