优化工件配送和空料架

This commit is contained in:
jinling.yang
2024-04-29 15:31:46 +08:00
parent 45220d75af
commit b1d42b9421
7 changed files with 137 additions and 102 deletions

View File

@@ -28,7 +28,7 @@ class Workpiece(http.Controller):
req_codes = ret['reqCode'].split(',')
for req_code in req_codes:
workpiece_delivery = request.env['sf.workpiece.delivery'].sudo().search(
[('delivery_num', '=', req_code.strip()), ('task_completion_time', '=', False)])
[('name', '=', req_code.strip()), ('task_completion_time', '=', False)])
if workpiece_delivery:
workpiece_delivery.write({'status': '已配送', 'task_completion_time': datetime.now()})
else: