diff --git a/sf_manufacturing/models/product_template.py b/sf_manufacturing/models/product_template.py index a9588024..c9d3fc48 100644 --- a/sf_manufacturing/models/product_template.py +++ b/sf_manufacturing/models/product_template.py @@ -27,6 +27,7 @@ class ResProductMo(models.Model): categ_type = fields.Selection(string='产品的类别', related='categ_id.type', store=True) model_name = fields.Char('模型名称') blank_type = fields.Selection([('圆料', '圆料'), ('方料', '方料')], string='坯料分类') + blank_precision = fields.Selection([('精坯', '精坯'), ('粗坯', '粗坯')], string='坯料类型') model_long = fields.Float('模型长(mm)', digits=(16, 3)) model_width = fields.Float('模型宽(mm)', digits=(16, 3)) model_height = fields.Float('模型高(mm)', digits=(16, 3)) @@ -902,6 +903,7 @@ class ResProductMo(models.Model): vals = { 'name': product_name, 'blank_type': item.get('blank_type'), + 'blank_precision': item.get('blank_precision'), 'model_long': item.get('blank_length') if blank_bool else self.format_float(item['model_long'] + embryo_redundancy_id.long), 'model_width': item.get('blank_width') if blank_bool else self.format_float(item['model_width'] + embryo_redundancy_id.width), 'model_height': item.get('blank_height') if blank_bool else self.format_float(item['model_height'] + embryo_redundancy_id.height),