agregar al composer
"miloschuman/yii2-highcharts-widget": "dev-master",
<?php
use yii\helpers\Html;
use miloschuman\highcharts\Highcharts;
use yii\web\JsExpression;
/*use app\modules\student\models\StuMaster;
use \app\modules\course\models\Batches;
$this->title = Yii::t('course', 'Manage Course Modules');
$this->params['breadcrumbs'][] = $this->title;
$this->registerCss(".disp-count{cursor:default;} .disp-count:hover {background-color:none !important}");*/
?>
<?php
echo Highcharts::widget([
'scripts' => [
'modules/exporting',
'themes/grid-light',
'highcharts-3d',
],
'options' => [
'exporting'=>[
'enabled'=>true
],
'credits'=>[
'enabled'=>false
],
'chart'=> [
'type'=>'pie',
],
'title' => ['text' => 'Fruit Consumption'],
'xAxis' => [
'categories' => ['Apples', 'Bananas', 'Oranges']
],
'yAxis' => [
'title' => ['text' => 'Fruit eaten']
],
'series' => [
['name' => 'Jane', 'data' => [1, 0, 4]],
['name' => 'John', 'data' => [5, 7, 3]]
]
]
]);
?>
No hay comentarios:
Publicar un comentario