浏览代码

Update manage.py

qiaofeng1227 2 年之前
父节点
当前提交
7feddaf39d
共有 1 个文件被更改,包括 3 次插入3 次删除
  1. 3 3
      appmanage/api/service/manage.py

+ 3 - 3
appmanage/api/service/manage.py

@@ -358,11 +358,11 @@ def check_app_rq(app_id):
     myLogger.info_logger(queue_job_ids)
     myLogger.info_logger(run_job_ids)
     myLogger.info_logger(failed_job_ids)
-    if not any(queue_job_ids) or not any(app_id in i for i in queue_job_ids):
+    if any(queue_job_ids) and any(app_id in i for i in queue_job_ids):
         return True 
-    if not any(failed_job_ids) or not any(app_id in i for i in failed_job_ids):
+    if any(failed_job_ids) and  any(app_id in i for i in failed_job_ids):
         return True  
-    if not any(run_job_ids) or not any(app_id in i for i in run_job_ids):
+    if any(run_job_ids) and any(app_id in i for i in run_job_ids):
         return True 
 
     return False