feat: 拆分任务类型并支持脚本语言联动

- 任务类型改为「执行脚本 / 发起 HTTP 请求 / 运行二进制程序」,脚本类型下新增语言选择(Python / Shell / Node / Lua)
- 语言联动表单:Python 才显示虚拟环境、解释器和 uv 状态;Shell/Node/Lua 隐藏这些字段并切换脚本标签、占位符和调用预览
- 切换语言时自动设置解释器与默认脚本,Shell 通过 cmd.exe /C 执行批处理,Node/Lua 使用对应解释器
- TaskAction 新增可选 language,旧任务按解释器推断;补 Shell 执行测试、语言切换单测与 Playwright 用例
This commit is contained in:
2026-11-04 22:07:14 +08:00
parent 8e6b3b92b9
commit 917674880b
15 changed files with 513 additions and 79 deletions
+3
View File
@@ -469,6 +469,8 @@ export interface components {
next_run_at?: string | null;
task_id: string;
};
/** @enum {string} */
ScriptLanguage: "python" | "shell" | "node" | "lua";
SessionResponse: {
/** @description Random per-process token required for mutating browser requests. */
token: string;
@@ -479,6 +481,7 @@ export interface components {
[key: string]: string;
};
interpreter: string;
language?: components["schemas"]["ScriptLanguage"] | null;
script: string;
/** @enum {string} */
type: "script";