Merge branch 'develop' of https://e.coding.net/jikimo-hn/jikimo_sfs/jikimo_sf into feature/新增上传模型功能
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
""",
|
||||
'category': 'sf',
|
||||
'website': 'https://www.sf.jikimo.com',
|
||||
'depends': ['account', 'base', 'mrp_workorder'],
|
||||
'depends': ['account', 'base', 'mrp_workorder','sale'],
|
||||
'data': [
|
||||
'security/group_security.xml',
|
||||
'security/ir.model.access.csv',
|
||||
@@ -18,6 +18,7 @@
|
||||
'views/common_view.xml',
|
||||
'views/fixture_view.xml',
|
||||
'views/functional_fixture_view.xml',
|
||||
# 'views/quick_easy_order_view.xml',
|
||||
'views/menu_view.xml',
|
||||
"views/tool_views.xml",
|
||||
"views/tool_menu.xml",
|
||||
|
||||
@@ -3,6 +3,8 @@ from . import common
|
||||
from . import tool_base_new
|
||||
from . import fixture
|
||||
from . import functional_fixture
|
||||
# from . import quick_easy_order
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -256,7 +256,7 @@ class MachineToolType(models.Model):
|
||||
name = fields.Char('名称')
|
||||
brand_id = fields.Many2one('sf.machine.brand', string='品牌')
|
||||
knife_type = fields.Selection(
|
||||
[("BT40", "BT40"), ("BT30", "BT30")],
|
||||
[("BT40", "BT40"), ("BT30", "BT30"), ("BT50", "BT50")],
|
||||
default="", string="刀把类型")
|
||||
number_of_knife_library = fields.Integer('刀库数量')
|
||||
rotate_speed = fields.Integer('转速')
|
||||
|
||||
26
sf_base/models/quick_easy_order.py
Normal file
26
sf_base/models/quick_easy_order.py
Normal file
@@ -0,0 +1,26 @@
|
||||
from odoo import models, fields
|
||||
import datetime
|
||||
import base64
|
||||
|
||||
|
||||
class QuickEasyOrder(models.Model):
|
||||
_name = 'quick.easy.order'
|
||||
_description = '简易下单'
|
||||
|
||||
name = fields.Char('订单编号', default=lambda self: self.env['ir.sequence'].next_by_code('quick.easy.order'))
|
||||
machining_precision = fields.Selection([
|
||||
('0.10', '±0.10mm'),
|
||||
('0.05', '±0.05mm'),
|
||||
('0.03', '±0.03mm'),
|
||||
('0.02', '±0.02mm'),
|
||||
('0.01', '±0.01mm')], string='加工精度')
|
||||
material_id = fields.Many2one('sf.production.materials', '材料')
|
||||
material_model_id = fields.Many2one('sf.materials.model', '型号')
|
||||
process_id = fields.Many2one('sf.production.process', string='表面工艺')
|
||||
parameter_ids = fields.One2many('sf.production.process.parameter', 'process_id', string='可选参数')
|
||||
quantity = fields.Integer('数量')
|
||||
price = fields.Float('总价')
|
||||
model_file = fields.Binary('模型文件')
|
||||
upload_model_file = fields.Many2many('ir.attachment', 'upload_qf_model_file_attachment_ref', string='上传模型文件')
|
||||
delivery_time = fields.Date('交货日期')
|
||||
customer_id = fields.Many2one('res.partner', string='客户', default=lambda self: self.env.user.partner_id.id)
|
||||
@@ -30,6 +30,7 @@
|
||||
<field name="name"/>
|
||||
<field name="tag_ids" widget="many2many_tags" optional="hide"/>
|
||||
<field name="remark"/>
|
||||
<field name="image_brand" widget="image"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
91
sf_base/views/quick_easy_order_view.xml
Normal file
91
sf_base/views/quick_easy_order_view.xml
Normal file
File diff suppressed because one or more lines are too long
@@ -2,35 +2,35 @@
|
||||
<odoo>
|
||||
<data>
|
||||
|
||||
<!-- 刀具物料action -->
|
||||
<!-- 刀具物料action -->
|
||||
<record id="action_sf_cutting_tool_material" model="ir.actions.act_window">
|
||||
<field name="name">刀具物料</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">sf.cutting.tool.material</field>
|
||||
<field name="view_mode">tree</field>
|
||||
</record>
|
||||
<!-- 刀具类型action -->
|
||||
<!-- 刀具类型action -->
|
||||
<record id="action_sf_cutting_tool_type" model="ir.actions.act_window">
|
||||
<field name="name">刀具类型</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">sf.cutting.tool.type</field>
|
||||
<field name="view_mode">tree</field>
|
||||
</record>
|
||||
<!-- 刀具型号action -->
|
||||
<!-- 刀具型号action -->
|
||||
<record id="action_sf_cutting_tool" model="ir.actions.act_window">
|
||||
<field name="name">刀具型号</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">sf.cutting.tool.model</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
</record>
|
||||
<!-- 功能刀具action -->
|
||||
<!-- 功能刀具action -->
|
||||
<record id="action_sf_functional_cutting_tool" model="ir.actions.act_window">
|
||||
<field name="name">功能刀具</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">sf.functional.cutting.tool</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
</record>
|
||||
<!-- 功能刀具类型 -->
|
||||
<!-- 功能刀具类型 -->
|
||||
<record id="action_sf_functional_cutting_tool_model_type" model="ir.actions.act_window">
|
||||
<field name="name">功能刀具类型</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
@@ -38,52 +38,53 @@
|
||||
<field name="view_mode">tree</field>
|
||||
</record>
|
||||
|
||||
<!-- 刀具 -->
|
||||
<!-- 刀具 -->
|
||||
<menuitem
|
||||
id="menu_sf_cutting_tool"
|
||||
parent="mrp.menu_mrp_configuration"
|
||||
name="刀具"
|
||||
sequence="4"
|
||||
/>
|
||||
<!-- 刀具物料 -->
|
||||
/>
|
||||
<!-- 刀具物料 -->
|
||||
<menuitem
|
||||
id="menu_sf_cutting_tool_material"
|
||||
parent="menu_sf_cutting_tool"
|
||||
name="刀具物料"
|
||||
sequence="1"
|
||||
action="action_sf_cutting_tool_material"
|
||||
/>
|
||||
<!-- 刀具类型 -->
|
||||
/>
|
||||
<!-- 刀具类型 -->
|
||||
<menuitem
|
||||
id="menu_sf_cutting_tool_type"
|
||||
parent="menu_sf_cutting_tool"
|
||||
name="刀具类型"
|
||||
sequence="2"
|
||||
action="action_sf_cutting_tool_type"
|
||||
/>
|
||||
<!-- 刀具型号 -->
|
||||
/>
|
||||
<!-- 刀具型号 -->
|
||||
<menuitem
|
||||
id="menu_sf_integral_cutting_tool"
|
||||
parent="menu_sf_cutting_tool"
|
||||
name="刀具型号"
|
||||
sequence="3"
|
||||
action="action_sf_cutting_tool"
|
||||
/>
|
||||
<!-- 功能刀具 -->
|
||||
/>
|
||||
<!-- 功能刀具 -->
|
||||
<menuitem
|
||||
id="menu_sf_functional_cutting_tool"
|
||||
parent="menu_sf_cutting_tool"
|
||||
name="功能刀具"
|
||||
sequence="5"
|
||||
action="action_sf_functional_cutting_tool"
|
||||
/>
|
||||
<!-- 功能刀具类型 -->
|
||||
/>
|
||||
<!-- 功能刀具类型 -->
|
||||
<menuitem
|
||||
id="menu_sf_functional_cutting_tool_model_type"
|
||||
parent="menu_sf_cutting_tool"
|
||||
name="功能刀具类型"
|
||||
sequence="4"
|
||||
action="action_sf_functional_cutting_tool_model_type"
|
||||
/>
|
||||
/>
|
||||
|
||||
</data>
|
||||
</odoo>
|
||||
|
||||
Reference in New Issue
Block a user