Browse Source

[FIX]Mandatory field product_uom_id missing

pull/124/head
Cybrosys Technologies 7 years ago
committed by GitHub
parent
commit
4e0b697c65
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      mrp_production_draft/models/mrp_production.py

2
mrp_production_draft/models/mrp_production.py

@ -48,6 +48,8 @@ class MrpProduction(models.Model):
@api.model
def create(self, values):
if not values.get('product_uom_id'):
values['product_uom_id'] = self.env['product.product'].browse(values['product_id']).uom_id.id
production = super(mp, self).create(values)
return production

Loading…
Cancel
Save