Filters are fields or drop downs that enable your
users to filter the list's data based on the data values. An example of how this looks to the user is as follows:
Whereas
pre-filters are chosen by the developer, filters are chosen by the user. The developer can set
pre-filters to be applied in combination with user filters, or to allow user filters to override the
pre-filters.
Filters can also be applied using the page URL.
Filter editing tab
The filter editing tab looks like this:
Filter trigger
The filter trigger defines when the filters get applied:
- On change - The table filters are applied immediately that they are changed by the user.
NOTE: If you have a cascading drop down as a filter then this option is not applicable and a 'GO' button will appear which will need to be pressed to submit the filter.
- Submit form - An "GO" button appears at the end of the filters. The table data is only filtered when this button is pressed.
Filters
The Filters setting defines the location of the filters on the screen and whether they start collapsed. The choices are as follows:
- No - Does not allow users the option of filtering.
- Above - Always displays filters above the table
- Above (toggleable) - Displays filters above the table, allowing the users to hide the filters
- Under headings - Displays the filters under the List's column headings
- Under headings (toggleable) - Displays the filters under the List's column headings, allowing the users to hide the filters
- Pop-up - Displays a pop-up window to enter the filter settings
Advanced search
Advanced search adds a button which will open a modal window which allows the user to build complex filter queries.
When the user clicks on this link, the advanced filter window opens.
From here your users can select which
Elements should meet which criteria for filtering the table. Pressing the "apply" button applies the filter to the table, pressing "clear filters" removes all the current advanced search filters.
Search All
Normal filters allow you to filter by values in specific fields. Sometimes the user needs to filter records for information which could be in any of several fields, and the Search All functional allows them to do this.
If you enable Search All then an additional search field will be added when you display the List allowing the user to search for text across the entire table.
Below is an example image of this feature in use:
Extended Search All
Extended Search All provides a similar facility using mySQL's Boolean full text search, allowing you to apply various criteria to your search terms. Please read these links for detailed information regarding how mySQL implements this feature:
http://dev.mysql.com/doc/refman/5.1/en/fulltext-boolean.html
http://dev.mysql.com/doc/refman/5.1/en/fulltext-fine-tuning.html
Important Notes:
Elements
The
Elements button opens a popup window allowing you to select which List
Elements are included in 'Search All' filters.
Search All Label
The Search All Label allows you to assign specific text to use for the Search all field (in the above example that is 'All').
Require filtering
If your List has a lot of rows, and you don't want to display any data until the user has defined some filters, then set Require Filtering to Yes.
Filter Data
The Filter Data setting defines what data to show in filters when rendered as a dropdown or range.
- Default - Fabrik's Global Configuration setting will be used
- Show table data - only values entered in this element's column will be shown in the filter.
- Show all - all possible Options will be shown (applies to 'list' type Elements such as checkboxes, radiobuttons, database joins).
Toggle Columns
Adds a button to the top of the list which enables users to toggle on/off columns and
Groups.
Filter Columns
If you are using the
Bootstrap Fabrik template, displays filters in a column layout with this number of columns.
Modifying the Filters template
Advanced Fabrik users can user Joomla's template override functionality to modify how Fabrik lays out the filter area for users.
The template file that is used to render the filter form is located in:
components/com_fabrik/views/list/{tmpl}/default_filter.php
Search for forum posts which describe how to implement template overrides.