Merge branch 'feature/库存优化' into feature/刀具优化
This commit is contained in:
@@ -357,6 +357,8 @@ class FunctionalToolAssembly(models.Model):
|
||||
"""
|
||||
智能工厂组装单处扫码校验刀具物料
|
||||
"""
|
||||
if 'O-CMD' in barcode:
|
||||
return ''
|
||||
for record in self:
|
||||
tool_assembly_id = self.env['sf.functional.tool.assembly'].browse(self.ids)
|
||||
lot_ids = self.env['stock.lot'].sudo().search([('rfid', '=', barcode)])
|
||||
@@ -835,7 +837,7 @@ class FunctionalToolAssembly(models.Model):
|
||||
|
||||
if options == '刀柄+整体式刀具':
|
||||
if not integral_ids:
|
||||
raise ValidationError('功能刀具清单的BOM未配置[刀柄]信息,请先配置BOM再开始组装!')
|
||||
raise ValidationError('功能刀具清单的BOM未配置[整体式刀具]信息,请先配置BOM再开始组装!')
|
||||
return {'options': options, 'handle_ids': handle_ids, 'integral_ids': integral_ids}
|
||||
elif options == '刀柄+刀杆+刀片':
|
||||
if not blade_ids:
|
||||
|
||||
@@ -298,8 +298,8 @@ class SfShelfLocationLot(models.Model):
|
||||
brand_id = fields.Many2one('sf.machine.brand', '品牌', related='product_id.brand_id')
|
||||
|
||||
cutting_tool_blade_diameter = fields.Float('刃部直径(mm)', related='product_id.cutting_tool_blade_diameter')
|
||||
cutting_tool_blade_tip_working_size = fields.Char('刀尖R角(mm)',
|
||||
related='product_id.cutting_tool_blade_tip_working_size')
|
||||
cutting_tool_blade_tip_working_size = fields.Float('刀尖R角(mm)',
|
||||
related='product_id.cutting_tool_blade_tip_r_size')
|
||||
cutting_tool_blade_radius = fields.Char('刀尖圆弧半径(mm)',
|
||||
related='product_id.cutting_tool_blade_tip_circular_arc_radius')
|
||||
cutting_tool_cutter_arbor_diameter = fields.Float('刀杆直径(mm)',
|
||||
|
||||
@@ -18,8 +18,7 @@
|
||||
<field name="arch" type="xml">
|
||||
<tree create="0" export_xlsx="0" delete="0">
|
||||
<header>
|
||||
<button string="确认" name="set_tool_material" type="object"
|
||||
class="treeHeaderBtn"/>
|
||||
<button string="确认" name="set_tool_material" type="object" class="treeHeaderBtn"/>
|
||||
</header>
|
||||
<field name="name"/>
|
||||
<field name="cutting_tool_type_id"/>
|
||||
@@ -62,6 +61,7 @@
|
||||
<field name="brand_id"/>
|
||||
<field name="shelf_location_id"/>
|
||||
<field name="lot_id"/>
|
||||
<field name="qty"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
@@ -86,6 +86,7 @@
|
||||
<field name="brand_id"/>
|
||||
<field name="shelf_location_id"/>
|
||||
<field name="lot_id"/>
|
||||
<field name="qty"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
@@ -111,6 +112,7 @@
|
||||
<field name="brand_id"/>
|
||||
<field name="shelf_location_id"/>
|
||||
<field name="lot_id"/>
|
||||
<field name="qty"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
@@ -135,6 +137,7 @@
|
||||
<field name="brand_id"/>
|
||||
<field name="shelf_location_id"/>
|
||||
<field name="lot_id"/>
|
||||
<field name="qty"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -478,9 +478,9 @@
|
||||
class="btn-primary"/>
|
||||
<button string="确认组装" name="functional_tool_assembly" type="object"
|
||||
attrs="{'invisible': [('assemble_status', 'not in', ['01'])]}"
|
||||
class="btn-primary"/>
|
||||
class="btn-primary jikimo_button_confirm"/>
|
||||
<button name="get_tool_preset_parameter" string="获取测量值"
|
||||
type="object" class="btn-primary"
|
||||
type="object" class="btn-primary jikimo_button_flushed"
|
||||
attrs="{'invisible': [('assemble_status', 'in', ['0','1','2'])]}"
|
||||
/>
|
||||
<field name="assemble_status" widget="statusbar" statusbar_visible="0,01,1"/>
|
||||
|
||||
Reference in New Issue
Block a user