Set planned date on inventory moves of shipments for issue1259

(transplanted from de0012795f472c56e5f5484f8c4deec1e1b6c093)
This commit is contained in:
Cédric Krier committed 2009-10-28 09:15:20 +01:00
1 parent c1674aa789
commit eb652b39b8
1 file changed
+5
+5
View File
@@ -267,6 +267,9 @@ class PackingIn(OSV):
res['to_location'] = incoming_move.packing_in.warehouse.\
storage_location.id
res['state'] = 'draft'
# Product will be considered in stock only when the inventory
# move will be made:
res['planned_date'] = False
res['company'] = incoming_move.company.id
return res
@@ -550,6 +553,7 @@ class PackingOut(OSV):
'quantity': out_quantity,
'packing_out': packing.id,
'state': 'draft',
'planned_date': shipment.planned_date,
'company': move.company.id,
'currency': move.company.currency.id,
'unit_price': unit_price,
@@ -631,6 +635,7 @@ class PackingOut(OSV):
'uom': move.uom.id,
'quantity': inv_quantity,
'packing_out': packing.id,
'planned_date': move.planned_date,
'state': 'draft',
'company': move.company.id,
}, context=context)