If condition

Set up actions to run if a row meets a certain condition, and optionally a different set of actions to run when it does not

Ingredient Family: rowActionsIngredients

Outline Display: Only perform the following if {{condition}} is true: {{innerAction}}
Otherwise, perform: {{elseAction}}

Details

Columns both branches add are visible to later steps; a column only one branch adds is not. The steps after this one run whichever branch ran, so only a column that both branches produce, under the same name and at the same type, is there for them to read; anything else is dropped at the merge. Give the two branches a column of the same name but different types and the check fails rather than silently dropping it. Leave elseAction unset when nothing should happen if the condition is false – an absent branch adds nothing, so nothing survives the merge.

Local scope

The parent slot binds these (look up the slot in the parent to see how):

  • $table – The table to act on

Names introduced within this component’s knobs:

  • $table/then – empty table populated by ingredients
  • $table/else – empty table populated by ingredients

Settings

Required

  • condition : formula (returns bool; required, non-nullable)
    The boolean formula choosing the branch; [Username] is the user running the action
    Scope: current time as [CURRENTTIMESTAMP], current username as [Username] (only where the handler authenticates: a logged-in page, or the calling user of an MCP tool, including inside its pipeline), all columns of $table (reference as [ColumnName], e.g., [Name], [Price])

Optional

  • innerAction : ingredient slot of rowActionsIngredients($table/then) (many)
    The action(s) to perform if the condition is True

  • elseAction : ingredient slot of rowActionsIngredients($table/else) (many)
    The action(s) to perform if the condition is False; omit this to do nothing in that case