[IMP] mrp: Solved tracking_id problem for Scrap products.

bzr revid: uco@tinyerp.com-20101018122707-70gywf01od71q8nn
This commit is contained in:
uco (OpenERP)
2010-10-18 17:57:07 +05:30
parent ed4308e114
commit cda1e07d44
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -128,7 +128,7 @@ class StockMove(osv.osv):
wf_service = netsvc.LocalService("workflow")
for move in self.browse(cr, uid, ids):
new_moves = super(StockMove, self).action_scrap(cr, uid, [move.id], product_qty, location_id, context=context)
self.write(cr, uid, [move.id], {'prodlot_id': False})
self.write(cr, uid, [move.id], {'prodlot_id': False, 'tracking_id': False})
production_ids = production_obj.search(cr, uid, [('move_lines', 'in', [move.id])])
for prod_id in production_ids:
wf_service.trg_validate(uid, 'mrp.production', prod_id, 'button_produce', cr)
+1 -1
View File
@@ -2090,7 +2090,7 @@ class stock_move(osv.osv):
'state': move.state,
'scrapped' : True,
'location_dest_id': location_id,
'tracking_id':False,
'tracking_id': move.tracking_id.id,
'prodlot_id': move.prodlot_id.id,
}
new_move = self.copy(cr, uid, move.id, default_val)