Open devalexandre opened 6 years ago
Please give some code, otherwise I have no way to help you.
Make sure you don't use dd()
anywhere, because that will destroy the session (this usually seems to be the problem for many people) And make sure you really have a session (API routes by default don't have a session)
https://gist.github.com/devalexandre/ac1f6410a434000f73f1fc760a55970f
when I use add work, but when I try get in other route using a getList, is are empty
This is worth a read - https://andremadarang.com/implementing-a-shopping-cart-in-laravel/
The repo for the example is here - https://github.com/drehimself/laravel-shopping-cart-example
Maybe you should use Cart::instance('default')->content()
instead of Cart::content()
?
when I use a add, it's wok but I try get items using Cart::content in other class, don't work