FilterMode: PP.TS.HieFilterMode;
The FilterMode property specifies type of filter for series in the hierarchy.
To execute the example, the page must contain the WorkbookBox component named workbookBox (see Example of Creating the WorkbookBox Component), and the following code must be added in the event handler that processes document opening:
var filterModeButton = new PP.Ui.Button({ ParentNode: document.body, //DOM parent node Content: "Filtering", //Text Click: PP.Delegate(filterModeClick) }); function filterModeClick() { //Get a component used to display and control workbook attributes var breadcrumb = workbookBox.getDataView().getBreadcrumb(); //Get the current hierarchy var hie = breadcrumb.getHierarchy(); if(hie.getFilterMode() == PP.TS.HieFilterMode.All) { //Set series filtering type in hierarchy hie.setFilterMode(PP.TS.HieFilterMode.None); } else { hie.setFilterMode(PP.TS.HieFilterMode.All); } var metaAttrTree = workbookBox.getDataView().getMetaAttrTree(); metaAttrTree.refreshAll(); }
After executing the example the Filtering button is placed in the HTML page. Filter of empty series and folders is set by default. To show this filter, select Hide in context menu of series tree. After clicking the Filtering button, filtering type for hierarchy series changes to No Filter.
See also: