Route workflow notifications to run history

This commit is contained in:
2026-06-09 18:49:59 +08:00
parent f8bdc3e952
commit 0cf20cc1ea
4 changed files with 7 additions and 6 deletions
+1
View File
@@ -1,4 +1,5 @@
VITE_APP_TITLE=AI Agent Admin
VITE_APP_NAMESPACE=ai-agent-admin
VITE_BASE=/ai-agent-admin/
VITE_GLOB_API_URL=/ai-agent-admin/basic-api
VITE_COMPRESS=none
@@ -237,11 +237,11 @@ export function useNotification() {
break;
}
case 'workflow_instance': {
path = `/app/workflow_center/workflow/initiated?id=${linkId}`;
path = `/ai-platform/workflow-runs?id=${linkId}`;
break;
}
case 'workflow_task': {
path = `/app/workflow_center/workflow/pending?id=${linkId}`;
path = `/ai-platform/workflow-runs?id=${linkId}`;
break;
}
// No default
@@ -63,11 +63,11 @@ function handleNotifyClick(msg: ChatMessage) {
break;
}
case 'workflow_instance': {
path = `/app/workflow_center/workflow/initiated?id=${extra.link_id}`;
path = `/ai-platform/workflow-runs?id=${extra.link_id}`;
break;
}
case 'workflow_task': {
path = `/app/workflow_center/workflow/pending?id=${extra.link_id}`;
path = `/ai-platform/workflow-runs?id=${extra.link_id}`;
break;
}
}
@@ -327,10 +327,10 @@ function handleGoToLink(message: Message) {
let url = '';
if (message.link_type === 'workflow_task') {
// 跳转到待办任务页面,带上任务ID
url = `/app/workflow_center/workflow/pending?id=${message.link_id}`;
url = `/ai-platform/workflow-runs?id=${message.link_id}`;
} else if (message.link_type === 'workflow_instance') {
// 跳转到我发起的页面,带上实例ID
url = `/app/workflow_center/workflow/initiated?id=${message.link_id}`;
url = `/ai-platform/workflow-runs?id=${message.link_id}`;
}
if (url) {