値で分岐(switch/case)
特定のフィールド値に応じて処理を分岐します。多くの値パターンがある場合、ifCondition のネストよりもシンプルに記述できます。
| パラメータ | 型 | 説明 |
|---|---|---|
switchField | フィールド選択 | 評価するフィールド |
cases | ケース定義 | 値とアクションの対応(JSON配列) |
switchCase (「ステータス」フィールド)├── case "未着手" → 初期設定アクション├── case "進行中" → 進捗管理アクション├── case "完了" → 完了処理アクション└── default → デフォルトアクションifCondition との使い分け
Section titled “ifCondition との使い分け”| 場面 | 推奨 |
|---|---|
| 1つのフィールドの値で多方向に分岐 | switchCase |
| 複数フィールドの複合条件 | ifCondition |
| 大小比較・範囲判定 | ifCondition |
| 単純な値の一致判定が多数 | switchCase |