From d0493ee8477c26ff5093a654b2d63adb64ed0164 Mon Sep 17 00:00:00 2001 From: Martin Trigaux Date: Fri, 10 Apr 2015 11:41:19 +0200 Subject: [PATCH] [FIX] sale: recompute tax amount after fiscal position change When changing the fiscal position of a sale.order, the taxes are recomputed which means that total amounts may no longer be correct (need to press 'update' button). Reset the amount_* fields to force the recomputation at write. Fixes lp:712772, opw 618419 --- addons/sale/sale.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/sale/sale.py b/addons/sale/sale.py index f182ab293f9..a669853287e 100644 --- a/addons/sale/sale.py +++ b/addons/sale/sale.py @@ -785,7 +785,7 @@ class sale_order(osv.osv): order_line.append([4, line_id]) else: order_line.append(line) - return {'value': {'order_line': order_line}} + return {'value': {'order_line': order_line, 'amount_untaxed': False, 'amount_tax': False, 'amount_total': False}} def test_procurements_done(self, cr, uid, ids, context=None): for sale in self.browse(cr, uid, ids, context=context):