diff --git a/app/run.py b/app/run.py index 27f23fe..90c49d1 100644 --- a/app/run.py +++ b/app/run.py @@ -135,7 +135,9 @@ def update(): def run_script_now(): if not is_login(): return "未登录" - command = [python_path, script_path, config_path] + payload = request.json + task_index = str(payload.get("task_index", "")) + command = [python_path, script_path, config_path, task_index] def generate_output(): process = subprocess.Popen( diff --git a/app/templates/index.html b/app/templates/index.html index c20f36b..b5ac3fd 100644 --- a/app/templates/index.html +++ b/app/templates/index.html @@ -131,7 +131,8 @@