From 34749ae6e6dfafc5348cda437360c3ba2d4ae0e3 Mon Sep 17 00:00:00 2001 From: Fu Diwei Date: Fri, 5 Sep 2025 16:12:19 +0800 Subject: [PATCH] fix: could not activate workflow again --- ui/src/pages/dashboard/Dashboard.tsx | 6 ++++++ ui/src/pages/workflows/WorkflowList.tsx | 5 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/ui/src/pages/dashboard/Dashboard.tsx b/ui/src/pages/dashboard/Dashboard.tsx index dece63cc..618c3124 100644 --- a/ui/src/pages/dashboard/Dashboard.tsx +++ b/ui/src/pages/dashboard/Dashboard.tsx @@ -268,6 +268,12 @@ const WorkflowRunHistoryTable = ({ className, style }: { className?: string; sty width: 48, render: (_, __, index) => index + 1, }, + { + key: "id", + title: "ID", + width: 160, + render: (_, record) => {record.id}, + }, { key: "name", title: t("workflow.props.name"), diff --git a/ui/src/pages/workflows/WorkflowList.tsx b/ui/src/pages/workflows/WorkflowList.tsx index c6d1ef7a..0eceb7a7 100644 --- a/ui/src/pages/workflows/WorkflowList.tsx +++ b/ui/src/pages/workflows/WorkflowList.tsx @@ -313,7 +313,7 @@ const WorkflowList = () => { const handleRecordActiveChange = async (workflow: WorkflowModel) => { try { - if (!workflow.enabled && !workflow.graphContent) { + if (!workflow.enabled && !workflow.hasContent) { message.warning(t("workflow.action.enable.errmsg.unpublished")); return; } @@ -326,7 +326,8 @@ const WorkflowList = () => { setTableData((prev) => { return prev.map((item) => { if (item.id === workflow.id) { - return resp; + item.enabled = resp.enabled; + item.updated = resp.updated; } return item; });