# 条件条件条件

Canonical URL: https://developers.iagenify.com/zh/sdk/workflows/steps/condition/
Language: zh

`type: "condition"`

两者是两个分支。它比较了两个数值,而图表是真实的还是虚假的,两者都必须存在。

Status: free · both branches required · 9 operators

| Name | Type | Requirement | Description |
| --- | --- | --- | --- |
| `left` | any |  | 通常是一个模板。 |
| `operator` | string | eq | 下九项中的一项。 |
| `right` | any |  | 与什么比较。 `exists` 和 `empty`. |

## 操作者 {#operators}

| 运算器 | 真实时当 |
| --- | --- |
| `eq` · `neq` | 平等与否 |
| `contains` | 左侧包含右侧。 |
| `gt` · `gte` · `lt` · `lte` | 分秩序比较。 |
| `exists` | 左边就在那里 |
| `empty` | 左侧为空 。 |

当工作流程保存时, 拒绝拒绝未知的操作员 。

## 要求两个分支处 {#edges}

```javascript
edges: [
  { from: "check", to: "urgent", branch: "true" },
  { from: "check", to: "normal", branch: "false" },
]
```

> **拒绝拒绝缺缺的分支, 而不是默认**
>
> 只有一个只有真实边缘的条件,只要答案是假的,就结束运行,没有字词,只要答案是假的。 要求两者都意味着每个路径都是某人写的。

## 输出 {#output}

```javascript
{{steps.check.output.result}}     // true or false
{{steps.check.output.left}}
{{steps.check.output.operator}}
```

## 剧本上的分行,不是在讲稿上 {#schema}

与 `schema` 测试是否免费文本含有一个字, 模式第一次打破“ 不急” 。

- [开关](/zh/sdk/workflows/steps/switch): 超过两个分支。
- [合并合并](/zh/sdk/workflows/steps/merge): 把他们带回来
- [工作流步骤](/zh/sdk/workflows/steps): 全部 23 种类型。

```python
edges = [
    {"from": "check", "to": "urgent", "branch": "true"},
    {"from": "check", "to": "normal", "branch": "false"},
]
```

```python
"{{steps.check.output.result}}"    # True or False
"{{steps.check.output.left}}"
"{{steps.check.output.operator}}"
```
