How to pass second dimension as drill down?

Hi Team Helical,

I have created a grouped bar chart. Which is Employee Wise, Type Wise, Cost of Travel. Now the drill down report only allows me to pass the first dimension i.e. Employee name whereas I want to drill down on the second type which is Type of Travel. how can that something like that be done. I am using Helical Insight version 3.0.

Thank You

Hello Shwetant,

By default, the grouping gets applied to the first dimension. In order to apply the drill down on the second dimension, please use the below code in JS editor section of the ad-hoc report. Since we are doing drill down through code, do not use the frontend driven drill down the script.

In the window. open provide the path of the drill down child report till &mode=dashboard. &Type will get replaced with the actual name of the dimension on which you are clicking. Here since we are clicking on TravelType this will be &TravelType

hi_container.set("preExecution",function(c){
var viz_Options = c.get("viz_Options");
viz_Options.chartOptions.data = {
onclick: function(d,i) {
console.log(d.name);
reportRender({type:d.name});
}
};
c.set("viz_Options",viz_Options);
});


function reportRender(filters) {
window.open("http://192.168.2.51:8081/hi-ee/hi.html?dir=1556529637242&file=fb313e5e-3371-4cad-827e-8127383ad6ae.report&mode=dashboard&Type="+filters.type,"_blank");
}

Thank You
Helical Insight Team,