You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error Object of class Gloudemans\Shoppingcart\CartItem could not be converted to string (View: C:\Users\Alasco\Desktop\laravel\e_shop\resources\views\livewire\cart-component.blade.php)
#656
Open
LepetitHero opened this issue
May 5, 2021
· 0 comments
Hi ! I've a new issue from my code.
When I try to add product to the cart, I get this issue.
this the controller
`use Cart;
public function store($product_id, $product_name, $product_price)
{
Cart::add($product_id, $product_name,1, $product_price)->associate('App\Models\Product');
session()->flash('success_message', 'item add in cart');
return redirect()->route('product.cart');
}`
this this the view code
`
Please, I need your help. Thanks!!
The text was updated successfully, but these errors were encountered: