This is the documentation for ConfiForms Server/Data Center app
In this tutorial we will demonstrate how to use a new feature of ConfiForms to construct dynamic filters over your stored data. The macro is called ConfiForms Dynamic Filter
If you are new to ConfiForms, please take a few minutes to read the Basic concepts Guide, or go through the video tutorial on that page.
|Field label||Field name||Type|
|My Text Field||mytffield||text|
|My Dropdown Field||mydropdownfield||advanced dropdown|
|My Text Area||mytextarea||textarea|
Something like this
We will add some records into the form
Now it is time to bring in the Dynamic Filter macro
Here is the macro, with the default settings it takes all the fields from the form and present them in a card view. You can easily change the layout of this, see below
But it does not work without a "view"... without "views" macros, such as CalendarView, ListView, TableView or CardView.
Trying to use it without a view will result in a warning message
So we need a "view"
We will use the default ConfiForms TableView
However, for TableView and CardView you *MUST* enable support for filter in macro properties
Now we can use the filter
Very important note:
You have to set the type of view used with this filter in Dynamic Filter macro. We have not done it, because the defaul mode is "table"
But this setting in ConfiForms Dynamic Filter macro must reflect what type of view macro you are trying to use with this filter
(name of the form and page where the form is located must match in "view" and in filter)
Here is an example using the Dynamic filter with custom layout and using it together with a ListView
- We have put ConfiForms Field macro inside the Dynamic Filter to force own layout and use only the fields we want
- We Enabled Filter for "list" (listview) in Dynamic Filter
- We created ListView with custom layout (ListView and CalendarView do not require filter support to be explicitely set, it is there by default. In TableView and CardView it is off by default to support clean tables and compatibility with COnfluence Chart macro)
Here is how it looks like on the page
Thank you for you time and reading this far. The tutorial now ends, but there is a bit more to explore in Dynamic Filter macro, such as:
- You can reduce the number of choices in dropdown fields (and all other choice-enabled fields) to show only available values
- When you enable inline search on "views" you will actually see what filter is used to filter
You can set "views" to show nothing initially (useful for large dataset). To do this you need to write some filter which will not match anything. One to suggest is to use internal field _today and compare it agains 0
Which is always false, as _today holds the current timestamp
More about filter can be found here: ConfiForms Filters
You can add a form reset button (setting in Dynamic Filter macro) to ease the clean up of fields to start over