For using drill-down functionality, user needs to create two reports i.e. a parent report & a child report:-
Parent report: Primary report to which the drill-down functionality is to be applied
Child report: Secondary report which will open in a new tab or at same place (depending upon the option selected)
Note: Child report should have a filter in which the value will get passed based on where we have clicked in the parent report. If the parent report is a grouped bar chart an onclick event will pass 2 dimensions. It is always better to create the Child report first. Child report can also have even more filters to get the values of the other filters which the parent report might also be having. So we created first child report, then parent report and then in the parent report we apply customization script.
In order to apply the drilldown script, click on the “Customize” button on the report create or report edit page.
Double click on the drilldown icon to open the following modal window
Click on the checkbox to select whether you want to open the child report in a new tab or in the same tab or you want to implement InterPanel Communication (IPC).
Here in this blog we are going to cover more about “Open in New Tab” or “Open in Current Tab”. If you want to implement InterPanel Communication please go through this blog. With interpanel communication as soon as we click in the chart here the other panels of the dashboard will get updated accordingly.
Open in New Tab: This option opens the child report in a new tab.
Open in Current Tab: When this option is selected, the child report opens in the same div/frame/tab as the parent report. So, the child report replaces the space occupied by the parent report. If this option is used, you can add a back button by applying the Back Button customization script. You can refer this blog to add back button.
Click on the Browse button to select the child report to be opened upon drilldown. The file browser will open. Browse to the child report. Select it by left click and then click on the “Select” button.
The report URL will be added in the placeholder. Select the X axis column as Category and the other dimension as Series. Series needs to be selected for group chart only.
Category is the first dimension and is shown on the X axis. In a grouped bar chart, the second dimension is represented by the individual bars. This is the Series.
As soon as the child report is selected, the filters in the child report are populated in the Category and Series dropdown. Select the appropriate filter names to be mapped.
Once selected, click on Ok and apply the customization by clicking on the small tick. Additionally, if you want to pass the selected filter values from parent report to child report, you can click on “Add” button to map parameters. The filter values are mapped by passing the filter ID. The ID is the number shown next to the filter label. So, filters can be recognised as “Filter_0”, “Filter_1” etc.
Click Ok. You will see Chart Drilldown icon is highlighted. Click on the small tick to apply the customization. If you are not using grouped bar chart and using single dimension charts such as bar chart, line chart, pie chart etc., then you can uncheck the Set Series checkbox to disable it.
Click on Ok and apply the customization by clicking on the small tick.
When you click on the bar, the respective values of the category and series are passed in the URL alongwith the filter value of the filter in the parameter section.
For More Info, Contact us at support@helicalinsight.com