[MERGE] Merged the branch for the fix of Chained locations: processing first move did not copy prod.lot in chained moves

bzr revid: jvo@tinyerp.com-20110624105725-291ci1yzam0d1i6q
This commit is contained in:
Jay Vora (OpenERP)
2011-06-24 16:27:25 +05:30
+2
View File
@@ -2132,6 +2132,8 @@ class stock_move(osv.osv):
self.write(cr, uid, [move.id], {'move_history_ids': [(4, move.move_dest_id.id)]})
#cr.execute('insert into stock_move_history_ids (parent_id,child_id) values (%s,%s)', (move.id, move.move_dest_id.id))
if move.move_dest_id.state in ('waiting', 'confirmed'):
if move.prodlot_id.id:
self.write(cr, uid, [move.move_dest_id.id], {'prodlot_id':move.prodlot_id.id})
self.force_assign(cr, uid, [move.move_dest_id.id], context=context)
if move.move_dest_id.picking_id:
wf_service.trg_write(uid, 'stock.picking', move.move_dest_id.picking_id.id, cr)