odoo/odoo#199927
Created by Nisarg Patel (nipl)
Statuses:
- legal/cla: Contributor License Agreement check
- ci/runbot: Odoo Test Suite
- ci/upgrade_enterprise: Test upgrades for enterprise master
- ci/template: Contact runbot team on discord for help.
- ci/style: Optional style check. Ignore it only if strictly necessary.
- ci/security: Required security check. Can only be ignored by security team.
- label
- odoo-dev:saas-17.4-fix-ecommerce-pricelist-management-on-address-page-nipl
- head
- d6dd909a102e77297e26d0b98b50852bfd564fff
- merged
- 6 months ago by Sales, Victor Feyens (vfe)
odoo/odoo | |
---|---|
saas-17.4 | #199927 |
18.0 | #202097 |
saas-18.1 | #202122 |
saas-18.2 | #202385 |
saas-18.3 | |
saas-18.4 | |
19.0 | |
master | #202826 |
[FIX] website_sale: pricelist recompute during checkout
Steps:
- Go to /shop as a guest (without logging in).
- Select a pricelist different from the default.
- Add a product to the cart and proceed to checkout.
- Fill in the address form and submit.
- Observe that the pricelist is reset to the default instead of retaining the
selected one.
Issue
- When a user selects a pricelist on the /shop page without logging in,
the selected pricelist resets to the default during checkout after filling in
the address form.
Cause
- The update_address method updates the partner_id of the sale.order
- During this process, the write method triggers a recomputation that resets the
pricelist_id to the default instead of preserving the user-selected pricelist.
Fix
- Assign the selected pricelist to partner_sudo.property_product_pricelist
before updating the sale order’s partner.
- This ensures that the pricelist remains unchanged throughout the checkout
process.
Affected Version-saas-17.4
opw-4455367
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr