From 13c33264e62f25e43b2169381b554b41af8f9f60 Mon Sep 17 00:00:00 2001 From: Goffin Simon Date: Wed, 9 Mar 2016 10:01:25 +0100 Subject: [PATCH] [FIX] purchase: _get_po_line_values_from_proc-sig Introduced by eefc76f Only the supplier taxes of the company set in the procurement must be set in the PO. Backport from f5989bc3d8f10a0354a7d085576276d4e1778fbd opw:671449 --- addons/purchase/purchase.py | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/purchase/purchase.py b/addons/purchase/purchase.py index e55d9ff98df..10218dba4d7 100644 --- a/addons/purchase/purchase.py +++ b/addons/purchase/purchase.py @@ -1423,6 +1423,7 @@ class procurement_order(osv.osv): new_context.update({'lang': partner.lang, 'partner_id': partner.id}) product = prod_obj.browse(cr, uid, procurement.product_id.id, context=new_context) taxes_ids = procurement.product_id.supplier_taxes_id + taxes_ids = taxes_ids.filtered(lambda x: x.company_id.id == procurement.company_id.id) # It is necessary to have the appropriate fiscal position to get the right tax mapping fiscal_position = False fiscal_position_id = po_obj.onchange_partner_id(cr, uid, None, partner.id, context=context)['value']['fiscal_position']