Accept Merge Request #1178: (release/release_2.1 -> develop)
Merge Request: 1、货架、货位添加循环货位标签;2、功能刀具拆解选取法人货位添加只能选择循环货位的过滤条件 Created By: @禹翔辉 Reviewed By: @马广威 Approved By: @马广威 Accepted By: @禹翔辉 URL: https://jikimo-hn.coding.net/p/jikimo_sfs/d/jikimo_sf/git/merge/1178
This commit is contained in:
@@ -819,7 +819,7 @@ class FunctionalToolDismantle(models.Model):
|
|||||||
integral_lot_id = fields.Many2one('stock.lot', string='整体式刀具批次', compute='_compute_functional_tool_num',
|
integral_lot_id = fields.Many2one('stock.lot', string='整体式刀具批次', compute='_compute_functional_tool_num',
|
||||||
store=True)
|
store=True)
|
||||||
integral_freight_id = fields.Many2one('sf.shelf.location', '整体式刀具目标货位',
|
integral_freight_id = fields.Many2one('sf.shelf.location', '整体式刀具目标货位',
|
||||||
domain="[('product_id', 'in', (integral_product_id, False)),('location_id.name', '=', '刀具房')]")
|
domain="[('product_id', 'in', (integral_product_id, False)),('rotative_Boolean', '=', True)]")
|
||||||
|
|
||||||
# 刀片
|
# 刀片
|
||||||
blade_product_id = fields.Many2one('product.product', string='刀片', compute='_compute_functional_tool_num',
|
blade_product_id = fields.Many2one('product.product', string='刀片', compute='_compute_functional_tool_num',
|
||||||
@@ -829,7 +829,7 @@ class FunctionalToolDismantle(models.Model):
|
|||||||
blade_brand_id = fields.Many2one('sf.machine.brand', string='刀片品牌', related='blade_product_id.brand_id')
|
blade_brand_id = fields.Many2one('sf.machine.brand', string='刀片品牌', related='blade_product_id.brand_id')
|
||||||
blade_lot_id = fields.Many2one('stock.lot', string='刀片批次', compute='_compute_functional_tool_num', store=True)
|
blade_lot_id = fields.Many2one('stock.lot', string='刀片批次', compute='_compute_functional_tool_num', store=True)
|
||||||
blade_freight_id = fields.Many2one('sf.shelf.location', '刀片目标货位',
|
blade_freight_id = fields.Many2one('sf.shelf.location', '刀片目标货位',
|
||||||
domain="[('product_id', 'in', (blade_product_id, False)),('location_id.name', '=', '刀具房')]")
|
domain="[('product_id', 'in', (blade_product_id, False)),('rotative_Boolean', '=', True)]")
|
||||||
|
|
||||||
# 刀杆
|
# 刀杆
|
||||||
bar_product_id = fields.Many2one('product.product', string='刀杆', compute='_compute_functional_tool_num',
|
bar_product_id = fields.Many2one('product.product', string='刀杆', compute='_compute_functional_tool_num',
|
||||||
@@ -839,7 +839,7 @@ class FunctionalToolDismantle(models.Model):
|
|||||||
bar_brand_id = fields.Many2one('sf.machine.brand', string='刀杆品牌', related='bar_product_id.brand_id')
|
bar_brand_id = fields.Many2one('sf.machine.brand', string='刀杆品牌', related='bar_product_id.brand_id')
|
||||||
bar_lot_id = fields.Many2one('stock.lot', string='刀杆批次', compute='_compute_functional_tool_num', store=True)
|
bar_lot_id = fields.Many2one('stock.lot', string='刀杆批次', compute='_compute_functional_tool_num', store=True)
|
||||||
bar_freight_id = fields.Many2one('sf.shelf.location', '刀杆目标货位',
|
bar_freight_id = fields.Many2one('sf.shelf.location', '刀杆目标货位',
|
||||||
domain="[('product_id', 'in', (bar_product_id, False)),('location_id.name', '=', '刀具房')]")
|
domain="[('product_id', 'in', (bar_product_id, False)),('rotative_Boolean', '=', True)]")
|
||||||
|
|
||||||
# 刀盘
|
# 刀盘
|
||||||
pad_product_id = fields.Many2one('product.product', string='刀盘', compute='_compute_functional_tool_num',
|
pad_product_id = fields.Many2one('product.product', string='刀盘', compute='_compute_functional_tool_num',
|
||||||
@@ -849,7 +849,7 @@ class FunctionalToolDismantle(models.Model):
|
|||||||
pad_brand_id = fields.Many2one('sf.machine.brand', string='刀盘品牌', related='pad_product_id.brand_id')
|
pad_brand_id = fields.Many2one('sf.machine.brand', string='刀盘品牌', related='pad_product_id.brand_id')
|
||||||
pad_lot_id = fields.Many2one('stock.lot', string='刀盘批次', compute='_compute_functional_tool_num', store=True)
|
pad_lot_id = fields.Many2one('stock.lot', string='刀盘批次', compute='_compute_functional_tool_num', store=True)
|
||||||
pad_freight_id = fields.Many2one('sf.shelf.location', '刀盘目标货位',
|
pad_freight_id = fields.Many2one('sf.shelf.location', '刀盘目标货位',
|
||||||
domain="[('product_id', 'in', (pad_product_id, False)),('location_id.name', '=', '刀具房')]")
|
domain="[('product_id', 'in', (pad_product_id, False)),('rotative_Boolean', '=', True)]")
|
||||||
|
|
||||||
# 夹头
|
# 夹头
|
||||||
chuck_product_id = fields.Many2one('product.product', string='夹头', compute='_compute_functional_tool_num',
|
chuck_product_id = fields.Many2one('product.product', string='夹头', compute='_compute_functional_tool_num',
|
||||||
@@ -859,7 +859,7 @@ class FunctionalToolDismantle(models.Model):
|
|||||||
chuck_brand_id = fields.Many2one('sf.machine.brand', string='夹头品牌', related='chuck_product_id.brand_id')
|
chuck_brand_id = fields.Many2one('sf.machine.brand', string='夹头品牌', related='chuck_product_id.brand_id')
|
||||||
chuck_lot_id = fields.Many2one('stock.lot', string='夹头批次', compute='_compute_functional_tool_num', store=True)
|
chuck_lot_id = fields.Many2one('stock.lot', string='夹头批次', compute='_compute_functional_tool_num', store=True)
|
||||||
chuck_freight_id = fields.Many2one('sf.shelf.location', '夹头目标货位',
|
chuck_freight_id = fields.Many2one('sf.shelf.location', '夹头目标货位',
|
||||||
domain="[('product_id', 'in', (chuck_product_id, False)),('location_id.name', '=', '刀具房')]")
|
domain="[('product_id', 'in', (chuck_product_id, False)),('rotative_Boolean', '=', True)]")
|
||||||
|
|
||||||
@api.onchange('functional_tool_id')
|
@api.onchange('functional_tool_id')
|
||||||
def _onchange_freight(self):
|
def _onchange_freight(self):
|
||||||
|
|||||||
@@ -254,6 +254,7 @@ class SfShelf(models.Model):
|
|||||||
shelf_height = fields.Float(string='货架高度(m)')
|
shelf_height = fields.Float(string='货架高度(m)')
|
||||||
shelf_layer = fields.Integer(string='货架层数')
|
shelf_layer = fields.Integer(string='货架层数')
|
||||||
layer_capacity = fields.Integer(string='层数容量')
|
layer_capacity = fields.Integer(string='层数容量')
|
||||||
|
shelf_rotative_Boolean = fields.Boolean('循环货架', default=False)
|
||||||
|
|
||||||
# 是否有货位
|
# 是否有货位
|
||||||
is_there_area = fields.Boolean(string='是否有货位', compute='_compute_is_there_area', default=False, store=True)
|
is_there_area = fields.Boolean(string='是否有货位', compute='_compute_is_there_area', default=False, store=True)
|
||||||
@@ -361,6 +362,7 @@ class ShelfLocation(models.Model):
|
|||||||
|
|
||||||
name = fields.Char('货位名称', required=True, size=20)
|
name = fields.Char('货位名称', required=True, size=20)
|
||||||
barcode = fields.Char('货位编码', copy=False, size=50)
|
barcode = fields.Char('货位编码', copy=False, size=50)
|
||||||
|
rotative_Boolean = fields.Boolean('循环货位', related='shelf_id.shelf_rotative_Boolean', store=True)
|
||||||
qr_code = fields.Binary(string='二维码', compute='_compute_location_qr_code', store=True)
|
qr_code = fields.Binary(string='二维码', compute='_compute_location_qr_code', store=True)
|
||||||
|
|
||||||
# 货架
|
# 货架
|
||||||
|
|||||||
@@ -23,6 +23,7 @@
|
|||||||
<field name="shelf_height" string="货架高度(m)"/>
|
<field name="shelf_height" string="货架高度(m)"/>
|
||||||
<field name="shelf_layer" string="货架层数"/>
|
<field name="shelf_layer" string="货架层数"/>
|
||||||
<field name="layer_capacity" string="层数容量"/>
|
<field name="layer_capacity" string="层数容量"/>
|
||||||
|
<field name="shelf_rotative_Boolean"/>
|
||||||
</group>
|
</group>
|
||||||
<notebook>
|
<notebook>
|
||||||
<page string="货位">
|
<page string="货位">
|
||||||
@@ -169,6 +170,7 @@
|
|||||||
<group>
|
<group>
|
||||||
<field name="barcode" readonly="1"/>
|
<field name="barcode" readonly="1"/>
|
||||||
<field name="name" readonly="1"/>
|
<field name="name" readonly="1"/>
|
||||||
|
<field name="rotative_Boolean" invisible="1"/>
|
||||||
<field name="shelf_id" readonly="1"/>
|
<field name="shelf_id" readonly="1"/>
|
||||||
<field name="location_id" readonly="1"/>
|
<field name="location_id" readonly="1"/>
|
||||||
<field name="product_id"/>
|
<field name="product_id"/>
|
||||||
|
|||||||
Reference in New Issue
Block a user