Hi,
i’m using highchart extension and i want to draw a chart using data from my Cgridview, can anyone help me to do it please
here is my CGridview
$this->widget('zii.widgets.grid.CGridView', array(
'id'=>'utilisateur-grid',
'dataProvider'=>$model->get_nb_sent(),
'filter'=>$model,
'columns'=>array(
'loginu',
'nbr',
'clicks',
'pr',
),
));
and this is an example of a chart,
<?php
$this->widget('application.extensions.highcharts.HighchartsWidget', array(
'options'=>array(
'chart'=> array('defaultSeriesType'=>'column',),
'title' => array('text' => 'TITLE'),
'legend'=>array('enabled'=>false),
'xAxis'=>array('categories'=>array('nama1','nama2','nama3','nama4','nama5'),),
'yAxis'=> array(
'min'=> 0,
'title'=> array(
'text'=>'Jumlah'
),
),
'series' => array(
array('data' => array(4,6,2,9,7))
),
'tooltip' => array('formatter' => 'js:function() {return "<b>"+ this.x +"</b><br/>"+"Jumlah : "+ this.y; }'),
'plotOptions'=>array('pie'=>(array(
'allowPointSelect'=>true,
'showInLegend'=>true,
'cursor'=>'pointer',
)
)
),
'credits'=>array('enabled'=>false),
)
));
i don’t know how to integrate it
thank you