From 95d22a563d9059b70e4e2db6f8158015187634d1 Mon Sep 17 00:00:00 2001 From: 3octaves <873551943@qq.com> Date: Mon, 2 Sep 2024 18:51:37 +0800 Subject: [PATCH] =?UTF-8?q?feat(frontend):=20=E4=BB=BB=E5=8A=A1=E4=B8=AD?= =?UTF-8?q?=E7=9A=84=E4=BA=BA=E5=B7=A5=E7=A1=AE=E8=AE=A4=E8=8A=82=E7=82=B9?= =?UTF-8?q?=E9=80=BB=E8=BE=91=E4=BC=98=E5=8C=96=20#6179?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dbm-ui/frontend/src/locales/zh-cn.json | 4 + .../views/task-history/common/graphRender.tsx | 2 +- .../components/PreviewNodeTree.vue | 18 +++ .../src/views/task-history/pages/Details.vue | 140 +++++++++++++----- .../common/components/flow-content/Index.vue | 27 +++- .../components/flow/components/Approve.vue | 7 +- .../components/approve/InnerManualConfirm.vue | 23 ++- .../flow/components/approve/ManualConfirm.vue | 7 +- 8 files changed, 178 insertions(+), 50 deletions(-) diff --git a/dbm-ui/frontend/src/locales/zh-cn.json b/dbm-ui/frontend/src/locales/zh-cn.json index 18ed5fd000..065e30fa72 100644 --- a/dbm-ui/frontend/src/locales/zh-cn.json +++ b/dbm-ui/frontend/src/locales/zh-cn.json @@ -3462,5 +3462,9 @@ "% 或 ? 不允许单独使用": "% 或 ? 不允许单独使用", "不允许为 *": "不允许为 *", "RedisCluster集群": "RedisCluster 集群", + "任务_待确认": "任务“待确认”", + "任务_执行成功": "任务“执行成功”", + "任务_执行失败": "任务“执行失败”", + "确认继续所有人工确认节点": "确认继续所有人工确认节点", "这行勿动!新增翻译请在上一行添加!": "" } diff --git a/dbm-ui/frontend/src/views/task-history/common/graphRender.tsx b/dbm-ui/frontend/src/views/task-history/common/graphRender.tsx index a50bf8bb29..dd19c66265 100644 --- a/dbm-ui/frontend/src/views/task-history/common/graphRender.tsx +++ b/dbm-ui/frontend/src/views/task-history/common/graphRender.tsx @@ -228,7 +228,7 @@ export default class GraphRender { {flowInfo.status !== 'REVOKED' && node.children === undefined && (
- {status === 'RUNNING' && ( + {!todoNodeIdList.includes(node.id) && status === 'RUNNING' && ( void; + getTreeRef: () => typeof treeRef; + isOpen: () => boolean; + } + withDefaults(defineProps(), { theme: 'error', children: 'children', @@ -112,6 +118,18 @@ const handleShowFailNodePanel = () => { isShowNodePanel.value = true; }; + + defineExpose({ + close() { + isShowNodePanel.value = false; + }, + getTreeRef() { + return treeRef; + }, + isOpen() { + return isShowNodePanel.value === true; + }, + });