mirror of
https://github.com/guohuadeng/app-odoo.git
synced 2025-02-23 04:11:36 +02:00
update product_seq
add all default
This commit is contained in:
@@ -73,7 +73,8 @@ class ProductProduct(models.Model):
|
||||
else:
|
||||
# create from product_product
|
||||
sequence = self.env['product.internal.type'].search([('id', '=', vals['internal_type'])], limit=1)
|
||||
vals['default_code'] = sequence.link_sequence.next_by_id()
|
||||
if sequence:
|
||||
vals['default_code'] = sequence.link_sequence.next_by_id()
|
||||
return super(ProductProduct, self).create(vals)
|
||||
|
||||
@api.multi
|
||||
|
||||
Reference in New Issue
Block a user