From cf51c506f71df40f7661663546e9d5b640682fb9 Mon Sep 17 00:00:00 2001 From: kevin Date: Tue, 21 Oct 2014 17:19:40 +0200 Subject: [PATCH] [FIX] stock: inverse function field should write the given value and not current --- addons/stock_account/stock.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/stock_account/stock.py b/addons/stock_account/stock.py index 295c17f5e1a..16483e76c26 100644 --- a/addons/stock_account/stock.py +++ b/addons/stock_account/stock.py @@ -191,7 +191,7 @@ class stock_picking(osv.osv): pick = self.browse(cr, uid, picking_id, context=context) moves = [x.id for x in pick.move_lines] move_obj= self.pool.get("stock.move") - move_obj.write(cr, uid, moves, {'invoice_state': pick.invoice_state}, context=context) + move_obj.write(cr, uid, moves, {'invoice_state': value}, context=context) _columns = { 'invoice_state': fields.function(__get_invoice_state, type='selection', selection=[