[FIX] receive and manually create a new one
bzr revid: fp@tinyerp.com-20110925232056-9t1lz4wf6t3ufjyz
This commit is contained in:
parent
b8140d9138
commit
371366702b
|
@ -848,7 +848,11 @@ class stock_picking(osv.osv):
|
|||
for pick in self.browse(cr, uid, ids, context=context):
|
||||
todo = []
|
||||
for move in pick.move_lines:
|
||||
if move.state == 'assigned':
|
||||
if move.state == 'draft':
|
||||
self.pool.get('stock.move').action_confirm(cr, uid, [move.id],
|
||||
context=context)
|
||||
todo.append(move.id)
|
||||
elif move.state in ('assigned','confirmed'):
|
||||
todo.append(move.id)
|
||||
if len(todo):
|
||||
self.pool.get('stock.move').action_done(cr, uid, todo,
|
||||
|
|
Loading…
Reference in New Issue