From 02ebe3312b071fb3f4d60610cd406f4afe8a3f38 Mon Sep 17 00:00:00 2001 From: "Quentin (OpenERP)" Date: Thu, 13 Dec 2012 10:53:04 +0100 Subject: [PATCH] [MERGE] mrp_repair: fixing the bug of operation type onchange, as of revision 8290, in a correct way bzr revid: qdp-launchpad@openerp.com-20121213095304-1td16oqz66lnj08g --- addons/mrp_repair/mrp_repair.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/addons/mrp_repair/mrp_repair.py b/addons/mrp_repair/mrp_repair.py index 905a1b5642f..17e9d9666fc 100644 --- a/addons/mrp_repair/mrp_repair.py +++ b/addons/mrp_repair/mrp_repair.py @@ -748,11 +748,13 @@ class mrp_repair_line(osv.osv, ProductChangeMixin): 'location_id': stock_id, 'location_dest_id': location_id }} + obj_data = self.pool.get('ir.model.data') + dummy, scrapped_location_id = obj_data.get_object_reference(cr, uid, 'stock', 'stock_location_scrapped') return {'value': { 'to_invoice': False, 'location_id': location_id, - 'location_dest_id': False + 'location_dest_id': scrapped_location_id, }} mrp_repair_line()