Build dependency between FilterForm fields


In FilterForm component, is there a way to configure a filter field that depends on another filter field? For example, if I choose “CA” in the State filter field, then I like the City filter field to list only cities in CA as options to choose.

1 Like


I don’t think FilterForm supports it out of box.

I would create an action that will update the data source of your City field and trigger it by the “change” event on the State filter field.

1 Like


An example of dependency filter behavior in the FilterForm component:

“behavior” : [{
  “query”: “myFieldSetID.myControlGroupId.State”, // Parent filter item ID (i.e. State)
  “trigger”: “change”,
  “action”: {
    “type”: “UpdateDataSourceFromSelect”,
    “dataSources”: [{
      “id”: “myDataSource.Cities”, // Datasource of the child filter item (i.e. City)
      “path”: “”, // A datasrouce field connected to the parent filter item
      “arrayValue”: false,
      “updateArgument”: “spec”,
      “updateField”: “filter”
    “followUpActions”: [{
      “action”: {
        “type”: “ClearForm”,
        “target”: “City”, // Child filter item ID
        “selectById”: true