Zadig 文档
Zadig
教程
博客
论坛
关于
中文英文
Zadig
教程
博客
论坛
关于
Zadig v4.2
Loading...
     编辑文档
     反馈问题
     社区讨论

    本页导航

    Workflow Dynamic Variables

    This article introduces the configuration and usage of dynamic variables in workflows.

    Applicable scenarios: Variable values in workflows need to be obtained from external systems or generated through coding.

    # How to Configure

    Configure workflow tasks, add variables, select the variable type as Dynamic Variable, and fill in the corresponding configuration.

    Configuration Instructions:

    • Variable Name: Can be used in scripts
    • Code block: Support Golang code block, requiring return []string
    • Calling Functions: Declare the functions to be called in the code block. Input parameters can come from other tasks in the workflow, in the format {{.key}}
    • Description: Description information for the variable

    Variable Configuration Description in the Figure Above:

    The figure above illustrates a cascading relationship between variables, where the number of values in the name variable is controlled by the num variable.

    • num: Control the number of user names returned by name
    • name: List of user names
      1. Code Block: Retrieves user names from an external system
      2. Calling Function: Calls the external system API to return a name string array, with the input parameter being {{.job.task1.num}}

    # Use Effect

    When executing the workflow, the number of values contained in the name variable will be adjusted according to the selected num variable value.

    ← Variable Passing in WorkflowsWorkflow Approval→

    资源
    教程
    论坛
    博客
    公司
    关于
    客户故事
    加入我们
    联系我们
    微信扫一扫
    hello@koderover.com

    © 2026 筑栈(上海)信息技术有限公司 沪 ICP 备 19000177 号 - 1

    •  跟随系统
    •  浅色模式
    •  深色模式
    •  阅读模式