From 40370b876f825f58ab3a9a39db4f6275561f343f Mon Sep 17 00:00:00 2001 From: caoqianming Date: Thu, 27 Mar 2025 17:21:58 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=88=86=E9=85=8D=E4=BB=BB=E5=8A=A1?= =?UTF-8?q?=E7=9A=84get=5Froutes=20=E5=8F=82=E6=95=B0bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/pm/services.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/pm/services.py b/apps/pm/services.py index 27afe22a..be120c0e 100644 --- a/apps/pm/services.py +++ b/apps/pm/services.py @@ -171,9 +171,10 @@ class PmService: gjson_item = utask.routepack.get_gjson(final_material_id=product.id) if not gjson_item: raise ParseError("缺少该产品的生产子图") - rqs = Route.get_routes(gjson_item["routes"]) + rqs = Route.get_routes(routeIds=gjson_item["routes"]) else: rqs = Route.get_routes(material=product) + if not rqs.exists(): raise ParseError('未配置工艺路线')