Skip to content
Snippets Groups Projects
Commit 7f1da074 authored by Thomas Lefebvre (thle)'s avatar Thomas Lefebvre (thle)
Browse files

[FIX] website_sale: clear old pricelist in the session

On the ecommerce, we want the pricelist to be adapted
to the user who is connected.
If no user is logged in, the 'Public Pricelist' is used.

To determine the pricelist that will be used (by default):
https://github.com/odoo/odoo/blob/a3169ede4f609b56c83da04756d20b1c7a07251f/addons/website_sale/controllers/main.py#L350-L354



Therefore, if we have been to the shop as a 'Public user' and we decide to log in,
we already have a pricelist in `request.session.get('website_sale_current_pl')`.

So we have to clear the pricelist when we connect to determine the new pricelist
of the user.

opw-3228998

closes odoo/odoo#118880

Signed-off-by: default avatarLefebvre Thomas (thle) <thle@odoo.com>
parent 77d8bc4e
Branches
Tags
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment