Cambiado el estado del nuevo albarán a borrador para poder editar las ubicaciones.
This commit is contained in:
parent
303a1c515c
commit
136ff98559
1 changed files with 1 additions and 2 deletions
|
@ -22,7 +22,6 @@ class ProductTemplate(models.Model):
|
|||
picking = self.env['stock.picking'].create(picking_vals)
|
||||
|
||||
for p in self:
|
||||
_logger.warning("product : %s" %p.name)
|
||||
move_vals = {
|
||||
'name': p.name,
|
||||
'product_id': p.id,
|
||||
|
@ -31,7 +30,7 @@ class ProductTemplate(models.Model):
|
|||
'picking_id': picking.id,
|
||||
'location_id': self.env.ref('stock.stock_location_stock').id,
|
||||
'location_dest_id': self.env.ref('stock.stock_location_stock').id,
|
||||
'state': 'waiting',
|
||||
'state': 'draft',
|
||||
'procure_method': 'make_to_order',
|
||||
}
|
||||
picking.move_lines = [(0, 0, move_vals)]
|
||||
|
|
Loading…
Add table
Reference in a new issue