Closed chan15 closed 1 year ago
public function index(Request $request, Cart $cart): View { $cart->addItem([ 'id' => 200, 'title' => 'chan', 'quantity' => 10, 'amount' => 200 ]); dd($cart->getItems()); }
I got
array:1 [▼ // app/Http/Controllers/Web/ShopController.php:21 "item_78381c3fb821cb4ab7abdde82a308930" => Jackiedo\Cart\Item {#418 ▶} ]
if I comment the set item code like:
public function index(Request $request, Cart $cart): View { // $cart->addItem([ // 'id' => 200, // 'title' => 'chan', // 'quantity' => 10, // 'amount' => 200 // ]); dd($cart->getItems()); }
I got:
[] // app/Http/Controllers/Web/ShopController.php:21
Shouldn't it keep in sessions?
Laravel: 9.45.1 Cart: 3.0
I got
if I comment the set item code like:
I got:
Shouldn't it keep in sessions?
Laravel: 9.45.1 Cart: 3.0