From 91e74557aa765903bf5afec5356c837bbaec5e5e Mon Sep 17 00:00:00 2001 From: v-me-50 Date: Wed, 25 Jun 2025 10:18:20 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=B9=B6=E8=A1=8C=E5=88=86?= =?UTF-8?q?=E6=94=AFconfig=E9=97=AE=E9=A2=98=20=E4=BF=AE=E5=A4=8D=E8=B7=B3?= =?UTF-8?q?=E8=BF=87=E9=80=9A=E7=9F=A5=E5=8F=96=E5=80=BC=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 4 +++- backend/internal/workflow/executor.go | 2 +- backend/internal/workflow/workflow.go | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 5b54b26..87f4d6e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,6 @@ .DS_Store /data/ /logs/ -.idea \ No newline at end of file +.idea +**/.history +**/.vscode \ No newline at end of file diff --git a/backend/internal/workflow/executor.go b/backend/internal/workflow/executor.go index 9b2d8e2..cf43d6a 100644 --- a/backend/internal/workflow/executor.go +++ b/backend/internal/workflow/executor.go @@ -209,7 +209,7 @@ func notify(params map[string]any) (any, error) { if v, ok := fromNodeData["skip"].(bool); ok && v { // 如果 skip 是 true,则跳过通知 var skip bool - switch v := fromNodeData["skip"].(type) { + switch v := params["skip"].(type) { case int: skip = v == 1 case float64: diff --git a/backend/internal/workflow/workflow.go b/backend/internal/workflow/workflow.go index 02bf4eb..bbe4986 100644 --- a/backend/internal/workflow/workflow.go +++ b/backend/internal/workflow/workflow.go @@ -246,7 +246,7 @@ func RunNode(node *WorkflowNode, ctx *ExecutionContext) error { errChan := make(chan error, len(node.ConditionNodes)) for _, branch := range node.ConditionNodes { if branch.ChildNode != nil { - if branch.ChildNode.ChildNode == nil { + if branch.ChildNode.Config == nil { branch.ChildNode.Config = make(map[string]any) } branch.ChildNode.Config["fromNodeData"] = node.Config["fromNodeData"]