Updating cart address at login

Help for integrating the Laravel package
Forum rules
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
User avatar
aimeos
Administrator
Posts: 7836
Joined: 01 Jan 1970, 00:00

Re: Updating cart address at login

Post by aimeos » 01 Dec 2015, 17:57

swpierce wrote: After successful login, I update the address in the cart if needed. I then grab the delivery service item and get the correct shipping. Works great. Post-login redirects to the basket view. Basket shows updated shipping but mini-basket still shows values from prior to logging in.
Well, the mini basket is cleared automatically by the basket standard component if something changes by using this method:
https://github.com/aimeos/aimeos-core/b ... ct.php#L27

The problem is that you do and can not use it because you are changing the basket directly. Thus, you need to clear the session manually.

As an alternative, you can disable caching for the small basket by using this config key:
https://github.com/aimeos/aimeos-core/b ... ct.php#L71
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

Post Reply