morris-js Morris.JS widget

  1. Requirements
  2. Usage
  3. Resources

MorrisJS widget for Yii. Quite simple.

Requirements

None AFAIK. Just vanilla Yii :)

Usage

$this->widget('application.extensions.morris.MorrisChartWidget', array(
    'id'      => 'myChartElement',
    'options' => array(
        'chartType' => 'Area',
        'data'      => array(
            array('y' => 2006, 'a' => 100, 'b' => 90),
            array('y' => 2007, 'a' => 40, 'b' => 60),
            array('y' => 2008, 'a' => 50, 'b' => 10),
            array('y' => 2009, 'a' => 60, 'b' => 50),
            array('y' => 2010, 'a' => 60, 'b' => 40),
        ),
        'xkey'      => 'y',
        'ykeys'     => array('a', 'b'),
        'labels'    => array('Series A', 'Series B'),
    ),
));

Resources

Morris.js is included

8 0
11 followers
835 downloads
Yii Version: 1.1
License: BSD-2-Clause
Category: Others
Developed by: eirikhm
Created on: Apr 25, 2013
Last updated: 4 years ago

Downloads

show all

Related Extensions