소스 검색

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

Amy0104 3 년 전
부모
커밋
e8e2e3a13d
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      dolphinscheduler-ui-next/src/views/projects/workflow/components/dag/use-cell-update.ts

+ 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) => {