修改退回工艺设计后再确认,采购单编程草稿状态
This commit is contained in:
@@ -57,6 +57,7 @@ class ProductionTechnologyWizard(models.TransientModel):
|
||||
# td_upd = self.env['sf.technology.design'].sudo().search(domain)
|
||||
# if td_upd:
|
||||
# ro.write({'sequence': td_upd.sequence, 'active': td_upd.active})
|
||||
# 特殊表面工艺
|
||||
special_design = self.env['sf.technology.design'].sudo().search(
|
||||
[('routing_tag', '=', 'special'), ('production_id', '=', production.id),
|
||||
('is_auto', '=', False), ('active', 'in', [True, False])])
|
||||
@@ -112,7 +113,9 @@ class ProductionTechnologyWizard(models.TransientModel):
|
||||
workorder.blocked_by_workorder_ids = blocked_by_workorder_ids[0]
|
||||
productions._create_workorder(False)
|
||||
if self.production_id.product_id.categ_id.type == '成品':
|
||||
productions.get_subcontract_pick_purchase()
|
||||
special_design_workorder = self.env['mrp.workorder'].search(
|
||||
[('technology_design_id', 'in', special_design.ids), ('production_id', '=', special.production_id.id), ('state', '!=', 'cancel')])
|
||||
productions.get_subcontract_pick_purchase(special_design_workorder)
|
||||
productions.is_adjust = False
|
||||
for item in productions:
|
||||
workorder = item.workorder_ids.filtered(lambda wo: wo.state not in ('cancel')).sorted(
|
||||
|
||||
Reference in New Issue
Block a user