修改工作流上下文

pull/79/head^2
zhangchenhao 2025-05-09 18:01:41 +08:00
parent f8f222e740
commit 6e2fe8cf52
1 changed files with 18 additions and 17 deletions

View File

@ -4,7 +4,6 @@ import (
"ALLinSSL/backend/public"
"encoding/json"
"fmt"
"strings"
"sync"
"time"
)
@ -192,13 +191,15 @@ func resolveInputs(inputs []WorkflowNodeParams, ctx *ExecutionContext) map[strin
for _, input := range inputs {
if input.FromNodeID != "" {
if val, ok := ctx.GetOutput(input.FromNodeID); ok {
switch strings.Split(strings.TrimPrefix(input.FromNodeID, "-"), "-")[0] {
case "apply":
input.Name = "certificate"
case "upload":
input.Name = "certificate"
}
resolved[input.Name] = val
// 暂时没有新的类型可以先写死
// switch strings.Split(strings.TrimPrefix(input.FromNodeID, "-"), "-")[0] {
// case "apply":
// input.Name = "certificate"
// case "upload":
// input.Name = "certificate"
// }
// resolved[input.Name] = val
resolved["certificate"] = val
}
}
}