Browse Source

处理失败,请联系管理员

rambo 8 tháng trước cách đây
mục cha
commit
7ff9ae375f
1 tập tin đã thay đổi với 6 bổ sung2 xóa
  1. 6 2
      python/api.py

+ 6 - 2
python/api.py

@@ -210,13 +210,17 @@ async def handle_detail(request: Request, params: HandlerDetail):
         print("out_put_dir", out_put_dir)
         print("goods_art_no", goods_art_no)
         print("goods_art_no not in out_put_dir", goods_art_no not in out_put_dir)
-        # 
+        #
         return {
             "code": 0,
             "msg": "详情处理完成",
             "data": {"out_put_dir": out_put_dir.replace("\\", "/")},
         }
-
+    else:
+        return {
+            "code": 1,
+            "msg": "处理失败,请联系管理员",
+            "data": None}
 
 @app.post("/get_device_configs", description="获取可执行程序命令列表")
 def get_device_configs(params: ModelGetDeviceConfig):