diff --git a/sf_base/models/tool_other_features.py b/sf_base/models/tool_other_features.py index b4f8b191..56c8c8a6 100644 --- a/sf_base/models/tool_other_features.py +++ b/sf_base/models/tool_other_features.py @@ -6,6 +6,7 @@ class ToolMaterialsBasicParameters(models.Model): _description = '刀具物料基本参数' standard_library_id = fields.Many2one('sf.cutting_tool.standard.library', string='刀具标准库') + specification_id = fields.Many2one('sf.cutting_tool.specification.wizard', string='刀具规格') cutting_tool_type = fields.Char(related='standard_library_id.cutting_tool_type', string='刀具物料类型', store=True) # cutting_tool_type_1 = fields.Char(related='cutting_tool_type', string='类型', store=True) @@ -288,7 +289,8 @@ class CuttingSpeed(models.Model): _name = 'sf.cutting.speed' _description = '切削速度Vc' - # product_template_id = fields.Many2one('product.template', string='产品') + product_template_id = fields.Many2one('product.template') + specification_id = fields.Many2one('sf.cutting_tool.specification.wizard', string='刀具规格') standard_library_id = fields.Many2one('sf.cutting_tool.standard.library', string='标准库') execution_standard_id = fields.Many2one('sf.international.standards', string='执行标准', store=True) material_code = fields.Char('材料代号') @@ -333,8 +335,9 @@ class FeedPerTooth(models.Model): _description = '每齿走刀量fz' _order = 'machining_method desc, blade_diameter, materials_type_id' - # product_template_id = fields.Many2one('product.template', string='产品') + product_template_id = fields.Many2one('product.template') standard_library_id = fields.Many2one('sf.cutting_tool.standard.library', string='标准库') + specification_id = fields.Many2one('sf.cutting_tool.specification.wizard', string='刀具规格') cutting_speed = fields.Char('径向切宽 ae(mm)') machining_method = fields.Selection([('直铣', '直铣'), ('坡铣', '坡铣')], string='加工方式') materials_type_id = fields.Many2one('sf.materials.model', string='材料型号') diff --git a/sf_base/static/src/scss/test.scss b/sf_base/static/src/scss/test.scss index a54eb808..d8761b94 100644 --- a/sf_base/static/src/scss/test.scss +++ b/sf_base/static/src/scss/test.scss @@ -161,4 +161,22 @@ td.o_required_modifier { display: flex !important; justify-content: flex-start !important; align-items: center !important; -} \ No newline at end of file +} + +//用于label外的div +.type_label { + display: flex; + align-items: center; +} + +.button_width button { + width:11rem; + margin-top: -9px; + height: 2.5rem; + line-height: 1.5rem; +} + +.button_width{ + display: flex; +} + diff --git a/sf_dlm/__init__.py b/sf_dlm/__init__.py index 737b4772..40272379 100644 --- a/sf_dlm/__init__.py +++ b/sf_dlm/__init__.py @@ -1 +1 @@ -# from . import models +from . import wizard diff --git a/sf_dlm/__manifest__.py b/sf_dlm/__manifest__.py index 42c4598a..85906b2b 100644 --- a/sf_dlm/__manifest__.py +++ b/sf_dlm/__manifest__.py @@ -16,7 +16,9 @@ 'data': [ 'data/product_data.xml', 'data/uom_data.xml', - # 'views/product_template_view.xml', + 'security/ir.model.access.csv', + 'wizard/cutting_tool_specification_wizard.xml', + 'views/product_template_view.xml', 'views/product_workorder.xml' ], 'demo': [ diff --git a/sf_dlm/security/group_security.xml b/sf_dlm/security/group_security.xml new file mode 100644 index 00000000..b8668782 --- /dev/null +++ b/sf_dlm/security/group_security.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/sf_dlm/security/ir.model.access.csv b/sf_dlm/security/ir.model.access.csv new file mode 100644 index 00000000..9039e2c1 --- /dev/null +++ b/sf_dlm/security/ir.model.access.csv @@ -0,0 +1,12 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +access_sf_cutting_tool_specification_wizard,sf_cutting_tool_specification_wizard,model_sf_cutting_tool_specification_wizard,base.group_user,1,1,1,1 + + + + + + + + + + diff --git a/sf_dlm/views/product_template_view.xml b/sf_dlm/views/product_template_view.xml index 055898f5..bcb0e894 100644 --- a/sf_dlm/views/product_template_view.xml +++ b/sf_dlm/views/product_template_view.xml @@ -51,6 +51,18 @@ attrs="{'invisible': ['|',('categ_type', '!=', '表面工艺'),('categ_type', '=', False)]}"/> +