Accept Merge Request #1554: (feature/修复表面工艺 -> develop)

Merge Request: 修复表面工艺

Created By: @杨金灵
Reviewed By: @胡尧
Approved By: @胡尧 
Accepted By: @杨金灵
URL: https://jikimo-hn.coding.net/p/jikimo_sfs/d/jikimo_sf/git/merge/1554
This commit is contained in:
杨金灵
2024-11-26 16:32:47 +08:00
committed by Coding
4 changed files with 24 additions and 15 deletions

View File

@@ -79,12 +79,8 @@ class ProductionTechnologyReAdjustWizard(models.TransientModel):
if line.product_id.server_product_process_parameters_id == workorder.surface_technics_parameters_id:
purchase_order.write({'state': 'cancel'})
else:
if special.route_id.routing_type == '表面工艺':
display_name = special.process_parameters_id.display_name
else:
display_name = special.route_id.display_name
workorder = self.env['mrp.workorder'].search(
[('name', '=', display_name), ('production_id', '=', special.production_id.id)])
[('technology_design_id', '=', special.id), ('production_id', '=', special.production_id.id)])
if not workorder:
if special.route_id.routing_type == '表面工艺':
product_production_process = self.env['product.template'].search(

View File

@@ -46,8 +46,8 @@ class ProductionTechnologyWizard(models.TransientModel):
if ro.route_id.routing_type == '表面工艺':
domain += [('process_parameters_id', '=', ro.process_parameters_id.id)]
elif ro.route_id.routing_tag == 'special' and ro.is_auto is False:
display_name = ro.route_id.display_name
domain += [('name', 'ilike', display_name)]
# display_name = ro.route_id.display_name
domain += [('id', '=', ro.id)]
elif ro.panel is not False:
domain += [('panel', '=', ro.panel)]
td_upd = self.env['sf.technology.design'].sudo().search(domain)