diff --git a/dolphinscheduler-ui-next/src/views/projects/workflow/components/dag/dag-toolbar.tsx b/dolphinscheduler-ui-next/src/views/projects/workflow/components/dag/dag-toolbar.tsx index 199f5ad5b..4ff8c2cb4 100644 --- a/dolphinscheduler-ui-next/src/views/projects/workflow/components/dag/dag-toolbar.tsx +++ b/dolphinscheduler-ui-next/src/views/projects/workflow/components/dag/dag-toolbar.tsx @@ -140,7 +140,22 @@ export default defineComponent({ * Back to the entrance */ const onClose = () => { - router.go(-1) + if (history.state.back !== '/login') { + router.go(-1) + return + } + if (history.state.current.includes('workflow/definitions')) { + router.push({ + path: `/projects/${route.params.projectCode}/workflow-definition` + }) + return + } + if (history.state.current.includes('workflow/instances')) { + router.push({ + path: `/projects/${route.params.projectCode}/workflow/instances` + }) + return + } } /**