增加依赖

This commit is contained in:
胡尧
2024-11-18 10:54:48 +08:00
parent bc0b8bdecb
commit 73aa4af118
6 changed files with 31 additions and 31 deletions

View File

@@ -361,16 +361,16 @@ class StockRule(models.Model):
i = 0
for k in (production.product_id.model_processing_panel.split(',')):
# 根据制造类型来选择成品工序模板
# if production.production_type == '自动化产线加工':
product_routing_workcenter = self.env['sf.product.model.type.routing.sort'].search(
[('product_model_type_id', '=', production.product_id.product_model_type_id.id)],
order='sequence asc'
)
# elif production.production_type == '人工线下加工':
# product_routing_workcenter = self.env['sf.manual.product.model.type.routing.sort'].search(
# [('manual_product_model_type_id', '=', production.product_id.product_model_type_id.id)],
# order='sequence asc'
# )
if production.production_type == '自动化产线加工':
product_routing_workcenter = self.env['sf.product.model.type.routing.sort'].search(
[('product_model_type_id', '=', production.product_id.product_model_type_id.id)],
order='sequence asc'
)
elif production.production_type == '人工线下加工':
product_routing_workcenter = self.env['sf.manual.product.model.type.routing.sort'].search(
[('manual_product_model_type_id', '=', production.product_id.product_model_type_id.id)],
order='sequence asc'
)
for route in product_routing_workcenter:
i += 1
technology_design_values.append(