From 4a01132b91606737b438990f05b052437fa77d1e Mon Sep 17 00:00:00 2001 From: "jinling.yang" Date: Thu, 26 Oct 2023 10:10:47 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E4=BA=A7=E5=93=81=E5=88=80?= =?UTF-8?q?=E5=85=B7=E5=8F=82=E6=95=B0=E9=87=8C=E7=9A=84=E8=B5=B0=E5=88=80?= =?UTF-8?q?=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sf_manufacturing/models/product_template.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/sf_manufacturing/models/product_template.py b/sf_manufacturing/models/product_template.py index e6fd1c39..297de837 100644 --- a/sf_manufacturing/models/product_template.py +++ b/sf_manufacturing/models/product_template.py @@ -151,7 +151,12 @@ class ResProductMo(models.Model): [])] if not self.cutting_tool_model_id.compaction_way_ids else [ (6, 0, self.cutting_tool_model_id.compaction_way_ids.ids)] self.cutting_speed_ids = self.cutting_tool_model_id.cutting_speed_ids - self.feed_per_tooth_ids = [(0, 0, {'product_template_id': product_template.id}) for product_template in + self.feed_per_tooth_ids = [(0, 0, {'product_template_id': product_template.id, + 'cutting_speed': product_template.cutting_speed, + 'machining_method': product_template.machining_method, + 'blade_diameter': product_template.blade_diameter, + 'materials_type_id': product_template.materials_type_id.id}) for + product_template in self.cutting_tool_model_id.feed_per_tooth_ids.filtered( lambda r: r.blade_diameter == self.specification_id.blade_diameter)]