Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejson
{
  "title": "My List",
  "schema": "...",
  "input": "...",
  "search": "serverside",
  "filter": [
    {
      "title": "First Name",
      "columnName": ["firstName"],
      "type": "text"
    },
    {
      "title": "Last Name",
      "columnName": ["lastName"],
      "type": "text"
    },
    {
      "title": "Age",
      "columnName": ["age"],
      "type": "text"
    },
    {
      "title": "Date of Birth",
      "columnName": ["birthDate"],
      "type": "dateRange"
    },
    {
      "title": "Gender",
      "columnName": ["gender"],
      "type": "selection",
      "multiple": true,
      "option": ["male", "female"]
    }
  ],
  "pagination": {
    "allow": true
  }
}

...

The filter fields will be listed on top of the list. Once the user has specified a filter value, the list will be reloaded with the specified filter value.

Info

In case no input parameter is specified, by default a property search on JSON documents is executed using the command property.json.search. The search filter conditions for this command are created automatically at client side based on the filter fields used by the user. No further settings required.

Passing filter values as input variables

...

to custom input URI

In case a custom input URI is defined, the selected filter values must be passed to the endpoint. This is done again using variable interpolation wheras the name of the variable must be the name of the column, the filter was applied to. Here is an example:

...

In case of a filter of type dateRange, the selected value will be passed as… TODO

Using a pipeline as custom input endpoint

In case you would like to call a custom pipeline in the input, you can do so by setting the $uri:pipeline URI like this example shows:

...

Info

Make sure the pipeline returns a JSON structure as required by the client in order to show the list items correctly.

Using property.json.search as custom input endpoint

In order to simplify the JSON search in the property store, you can use the command property.json.search and customize its parameters to fit your special needs. This command already returns the required format without the need of further transformation. Here is an example how to use and customize it inside a pipeline with input variables passed from the client:

...