定制 maddoger/yii2-highcharts 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

maddoger/yii2-highcharts

最新稳定版本:v1.0.2

Composer 安装命令:

composer require maddoger/yii2-highcharts

包简介

jQuery Highcharts extension for the Yii 2 framework

README 文档

README

Highcharts widget is a wrapper of Highcharts for Yii2 Framework.

Installation

The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist maddoger/yii2-highcharts "*"

or add

"maddoger/yii2-highcharts": "*"

to the require section of your composer.json file.

Usage

Once the extension is installed, simply use it in your code by:

use maddoger\widgets\Highcharts;

echo Highcharts::widget([
        'chartVariable' => 'cpuChart',
        'options' => [
            'style' => 'width: 100%; height: 400px;',
        ],
        'clientOptions' => [
            'chart' => [
                'type' => 'line',
            ],
            'title' => [
                'text' => 'CPU Usage',
            ],
            'xAxis' => [
                'type' => 'datetime',
                'tickPixelInterval' => 150,
                'maxZoom' => 20 * 2000,
            ],
            'yAxis' => [
                'min' => 0,
                'max' => 100,
                'title' => [
                    'text' => '%',
                ],
            ],
            'series' => [
                [
                    'name'=> 'Core 1',
                    'data'=> [],
                ],
                [
                    'name'=> 'Core 2',
                    'data'=> [],
                ],
            ],
        ],
    ]);

统计信息

  • 总下载量: 184
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: Apache
  • 更新时间: 2015-10-09