6
0
Fork 0

预售商品 购物车列表

base
panliang 2022-08-01 09:43:16 +08:00
parent 6dd00e6da8
commit 464dc5662c
1 changed files with 2 additions and 0 deletions

View File

@ -88,6 +88,8 @@ class ShoppingCartItemController extends Controller
throw new ProductOfflineException(); throw new ProductOfflineException();
} }
$sku->load('spu');
if ($input['quantity'] > $sku->saleable_stock) { if ($input['quantity'] > $sku->saleable_stock) {
throw new ProductNotEnoughException(); throw new ProductNotEnoughException();
} }