Configuration for displaying the hierarchy of filters
Create the configuation to pass in your view.
title — A string displayed for the button texttoMsg — The message which is responsible for updating the Criteria.State in your modeltoId — A function taking a filter and returning a unique string which represent the filtertostring — A function taking a filter and returning a string which will be used as label in the hierarchygetSubFilters — A fuction taking a filter and returning the a list of its sub-filtersDefine if the hierarchy of filters is open the set of the selected filters the set of filters where the sub-filters are displayed State False Set.empty
Initialise the state, ie filters are hidden and no filter selected yet
import Criteria
Criteria.initReturn the set of the selected filters' id
The view function which take the configuration the state and a list of filters