调整程序写入逻辑

This commit is contained in:
mgw
2025-02-08 16:00:07 +08:00
parent 44f29d001e
commit 976d75973d
2 changed files with 4 additions and 3 deletions

View File

@@ -103,7 +103,8 @@ class Sf_Mrs_Connect(http.Controller, MultiInheritController):
try:
logging.info(f'已更新制造订单:{productions}')
re_tool_chekout = False
re_tool_chekout = productions.production_cnc_tool_checkout()
productions_temp = productions.filtered(lambda p: p.production_type == '自动化产线加工')
re_tool_chekout = productions_temp.production_cnc_tool_checkout()
if re_tool_chekout:
return json.JSONEncoder().encode({'status': -3, 'message': '对cnc工单的程序用刀进行校验失败'})
except Exception as e: