From 1ef3f540c2f4b5c32e3611f9d456fe14dbfe2209 Mon Sep 17 00:00:00 2001 From: CityFun <31820853+zhengkunwang223@users.noreply.github.com> Date: Fri, 12 Dec 2025 16:07:12 +0800 Subject: [PATCH] feat: Task center supports switching nodes (#11315) --- frontend/src/api/modules/log.ts | 5 +- frontend/src/components/node-select/index.vue | 48 +++++++++++++++++++ frontend/src/components/task-list/index.vue | 19 ++++---- 3 files changed, 61 insertions(+), 11 deletions(-) create mode 100644 frontend/src/components/node-select/index.vue diff --git a/frontend/src/api/modules/log.ts b/frontend/src/api/modules/log.ts index 22e2adf4f..de01f26b0 100644 --- a/frontend/src/api/modules/log.ts +++ b/frontend/src/api/modules/log.ts @@ -18,8 +18,9 @@ export const cleanLogs = (param: Log.CleanLog) => { return http.post(`/core/logs/clean`, param); }; -export const searchTasks = (req: Log.SearchTaskReq) => { - return http.post>(`/logs/tasks/search`, req); +export const searchTasks = (req: Log.SearchTaskReq, node?: string) => { + const params = node ? `?operateNode=${node}` : ''; + return http.post>(`/logs/tasks/search${params}`, req); }; export const countExecutingTask = () => { diff --git a/frontend/src/components/node-select/index.vue b/frontend/src/components/node-select/index.vue new file mode 100644 index 000000000..eef73e52f --- /dev/null +++ b/frontend/src/components/node-select/index.vue @@ -0,0 +1,48 @@ + + + diff --git a/frontend/src/components/task-list/index.vue b/frontend/src/components/task-list/index.vue index e1c0ea482..6fd8cd93d 100644 --- a/frontend/src/components/task-list/index.vue +++ b/frontend/src/components/task-list/index.vue @@ -1,13 +1,10 @@