Compare commits

...

2 Commits

Author SHA1 Message Date
liaodanlong
77c303e1fe Merge remote-tracking branch 'origin/develop' into develop 2024-11-05 10:59:36 +08:00
liaodanlong
ba9ce1f0ee 刀具标准库图片相关的参数更新 2024-11-05 10:58:46 +08:00

View File

@@ -2271,9 +2271,9 @@ class Cutting_tool_standard_library(models.Model):
[('code', '=', item['chuck_code'].replace("JKM", result['factory_short_name']))]).id,
"handle_id": False if not item['handle_code'] else self.search(
[('code', '=', item['handle_code'].replace("JKM", result['factory_short_name']))]).id,
"suitable_machining_method_ids": [(6, 0, [])] if not item.get(
'suitable_machining_methods') else self.env['maintenance.equipment.image']._get_ids(
item['suitable_machining_methods']),
"suitable_machining_method_ids": [(6, 0, [])] if not item.get('suitable_machining_method')
else self.env['maintenance.equipment.image']._get_ids(
item['suitable_machining_method']),
"blade_tip_characteristics_id": self.env['maintenance.equipment.image'].search(
[('name', '=', item['blade_tip_characteristics'])]).id,
"handle_type_id": self.env['maintenance.equipment.image'].search(
@@ -2304,6 +2304,7 @@ class Cutting_tool_standard_library(models.Model):
("active", 'in', [True, False])])
cutting_tool_type = self.env['sf.cutting.tool.type'].search(
[("code", '=', item['cutting_tool_type_code'])])
cutting_tool_material = self.env['sf.cutting.tool.material'].search(
[("code", '=', item['cutting_tool_material_code'])])
materials_model = self.env['sf.materials.model'].search(