[Fix] stock: fix the sale_id problem

bzr revid: sbh@tinyerp.com-20100809060651-x3ejmw42gtmnancv
This commit is contained in:
sbh (Open ERP) 2010-08-09 11:36:51 +05:30
parent 439ab66be7
commit cd13ee8fe7
1 changed files with 1 additions and 1 deletions

View File

@ -1583,7 +1583,7 @@ class stock_move(osv.osv):
'address_id': picking.address_id.id,
'invoice_state': 'none',
'date': picking.date,
'sale_id': picking.sale_id.id
'sale_id':' sale_id' in picking._columns.keys() and picking.sale_id.id or False
})
for move, (loc, auto, delay, journal, company_id, ptype) in todo:
new_id = move_obj.copy(cr, uid, move.id, {