Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines
You can use the following example for Drilldown with stacked column chart:
https://www.koolreport.com/examples/reports/drilldown/drilldown/
Change the single series column chart to a multi-series stacked one and replace the following drill down command:
saleDrillDown.next({year:params.selectedRow[0]});
to using your column name, row value, etc. You can show value structure of params with this to know how to get needed parameters:
// saleDrillDown.next({year:params.selectedRow[0]});
console.log("params:", params);
Here's an example of multi-column ColumnChart in DrillDown:
ColumnChart::create(array(
...
"columns"=>array(
"year"=>array(...),
"sale_amount"=>array(...),
"sale_amount2"=>array(...),
),
"clientEvents"=>array(
"itemSelect"=>"function(params){
console.log('params: ', JSON.stringify(params, null, 2));
}",
),
And here's the params when a column is clicked:
{
"selectedRowIndex": 0,
"selectedColumnIndex": 2,
"selectedValue": 6500435.400000001,
"selectedRow": [
"2003",
3250217.7000000007,
6500435.400000001
],
"columnName": "Sale Amount 2",
...
}
Based on this you can pass the column name, index, or value to the next chart/table in DrillDown.
Let KoolReport help you to make great reports. It's free & open-source released under MIT license.
Download KoolReport View demo