[FIX] purchase: use order date to set the picking date

When creating a pickign from a purchase order, do not use the schedule date
('date_planned') to specify the creation date ('date') of a picking.
There is already field called Scheduled Date ('min_date') and Max Expected Date
('max_date') that can display this information, this is redundand.

Fixes #4352
This commit is contained in:
Martin Trigaux 2015-04-02 17:47:32 +02:00
parent 506c229cd3
commit cbd396d3da
1 changed files with 1 additions and 1 deletions

View File

@ -842,7 +842,7 @@ class purchase_order(osv.osv):
picking_vals = {
'picking_type_id': order.picking_type_id.id,
'partner_id': order.partner_id.id,
'date': max([l.date_planned for l in order.order_line]),
'date': order.date_order,
'origin': order.name
}
picking_id = self.pool.get('stock.picking').create(cr, uid, picking_vals, context=context)