Browse Source

[Fix][UI Next][V1.0.0-Alpha] Fix the edge missing after editing the first task node in dag page. (#8947)

Amy0104 3 years ago
parent
commit
e8e2e3a13d

+ 3 - 1
dolphinscheduler-ui-next/src/views/projects/workflow/components/dag/use-cell-update.ts

@@ -86,7 +86,9 @@ export function useCellUpdate(options: Options) {
     const edges = getNodeEdge(id)
     if (edges?.length) {
       edges.forEach((edge) => {
-        graph.value?.removeEdge(edge)
+        if (edge.getTargetNode()?.id === id) {
+          graph.value?.removeEdge(edge)
+        }
       })
     }
     preTaskCode.forEach((task) => {