From 318d2d9cfa3ffa22f2619dccf28dc65a891e110a Mon Sep 17 00:00:00 2001 From: Edward Yang Date: Wed, 12 Apr 2023 11:40:56 +0800 Subject: [PATCH] Fixed customer group discount. --- beike/Shop/Services/TotalServices/CustomerDiscountService.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/beike/Shop/Services/TotalServices/CustomerDiscountService.php b/beike/Shop/Services/TotalServices/CustomerDiscountService.php index 27d95666..d8f89532 100644 --- a/beike/Shop/Services/TotalServices/CustomerDiscountService.php +++ b/beike/Shop/Services/TotalServices/CustomerDiscountService.php @@ -31,8 +31,8 @@ class CustomerDiscountService if ($discountFactor <= 0) { return null; } - if ($discountFactor > 1) { - $discountFactor = 1; + if ($discountFactor > 100) { + $discountFactor = 100; } $amount = $totalService->getSubTotal() * $discountFactor / 100;