From 700dfd12c6d07bde9f3e09f9a980a331e61d147a Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Fri, 20 Dec 2013 13:54:34 +0100 Subject: [PATCH] [REV] stock: removed feature that was looking if a procurement was in exception (because all its moves were cancelled) at the time of _run_move_create and which cancel the previously made attempt (to avoid duplicates). The reason of this removal is that it may have side effects, and that we prefer let the users manually fix exceptions (dixit fp) bzr revid: qdp-launchpad@openerp.com-20131220125434-gtpowwy8q6m1z5tl --- addons/stock/procurement.py | 6 ------ 1 file changed, 6 deletions(-) diff --git a/addons/stock/procurement.py b/addons/stock/procurement.py index 67402466942..27a7b49120e 100644 --- a/addons/stock/procurement.py +++ b/addons/stock/procurement.py @@ -197,12 +197,6 @@ class procurement_order(osv.osv): 'date_expected': newdate, 'propagate': procurement.rule_id.propagate, } - #look if the procurement was in exception (because all its moves were cancelled) and cancel the previously made attempt to avoid duplicates - cancelled_moves = [m.id for m in procurement.move_ids if m.state == 'cancel'] - if cancelled_moves: - previous_attempt = self.search(cr, uid, [('move_dest_id', 'in', cancelled_moves)], context=context) - if previous_attempt: - self.cancel(cr, uid, previous_attempt, context=context) return vals def _run(self, cr, uid, procurement, context=None):