Hi Support team,
I have a requirement from my customer. I have to implement Drilldown with 3 different charts in 3 levels ie in
Level 1: Column Chart, Level 2: Donut Chart or Pie Chart, Level 3: Grid view with Export Excel Or PDF
How can I do this? Can you give me some example...
I changed my graph from ColumnChart to Donut Chart in Level2, it displays correctly. But it doesn't propagate to 3 Level. Here is my Code
DrillDown::create(array(
"name"=> "saleDrillDown",
"title"=>"Sale Report",
"levels"=>array(
array( //level1
"title" => "All Years",
"content"=>function($params,$scope){
ColumnChart::create(array(
"dataSource"=>(
$this->src("invoice")->query("SELECT Year,SUM(InvValue) as invoice from MonthWiseSalesSummeriesNew group by Year Order by Year") ),
"columns"=>array(
"Year",
"invoice"
),//columns end
"clientEvents"=>array(
"itemSelect" => "function(params){
saleDrillDown.next({Year:params.selectedRow[0]});
}",
)//clientEvents end
));//ColumnChart1
}
), //Level1 End
array(
"title" => function($params,$scope)
{
return "Year ".$params["Year"];
},
"content"=>function($params,$scope)
{
DonutChart::create(array(
"dataSource"=>(
$this->src("invoice")->query("
SELECT Year,Month,SUM(InvValue) as invoice from MonthWiseSalesSummeriesNew where Year=:Year
group by Year,Month
Order by Year,Month
")
->params(array(
":Year" =>$params["Year"]
))
),//dataSource End
"columns"=>array(
"Month",
"invoice"),
"clientEvents"=>array(
"itemSelect" => "function(params){
saleDrillDown.next({Month:params.selectedRow[0]});
}",
)//clientEvents end
));///DonutChart2
}//content end
),//Level2