From 95482184455bd50158f9df4270ec1569fc62d07c Mon Sep 17 00:00:00 2001 From: Walid Date: Fri, 3 Nov 2023 10:58:26 +0100 Subject: [PATCH] [FIX] purchase: wrong list price UoM Steps to reproduce: - Install Sale and Purchase and enable UoM - Change 'Acoustic bloc screen' purchase UoM to dozen - Create a PO for that product - Access the product page from PO line - Wrong Sales price Bug: the jsonrpc to read product data needlesslt sends the UoM in the context which leads to the sales price being updated by _compute_product_lst_price Fix: remove UoM from procut context as it is not necessary opw-3434574 closes odoo/odoo#140957 X-original-commit: fe04d61a886fa7b461ebf9bda2d7479fb69281cd Signed-off-by: William Henrotin (whe) Signed-off-by: Walid Hanniche (waha) --- addons/purchase/views/purchase_views.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/purchase/views/purchase_views.xml b/addons/purchase/views/purchase_views.xml index 8bea6a34beb..dcbee5fa80d 100644 --- a/addons/purchase/views/purchase_views.xml +++ b/addons/purchase/views/purchase_views.xml @@ -235,7 +235,7 @@ readonly="state in ('purchase', 'to approve', 'done', 'cancel')" required="not display_type" width="35%" - context="{'partner_id':parent.partner_id, 'quantity':product_qty,'uom':product_uom, 'company_id': parent.company_id}" + context="{'partner_id':parent.partner_id, 'quantity':product_qty, 'company_id': parent.company_id}" force_save="1" domain="[('purchase_ok', '=', True), '|', ('company_id', '=', False), ('company_id', '=', parent.company_id)]"/>