kokjan/vendor/kongoon/yii2-orgchart
Manop Kongoon 35a9c7f61d style: reduce font size of statistics table in footer 2026-02-27 07:03:00 +07:00
..
OrgChart.php style: reduce font size of statistics table in footer 2026-02-27 07:03:00 +07:00
README.md style: reduce font size of statistics table in footer 2026-02-27 07:03:00 +07:00
composer.json style: reduce font size of statistics table in footer 2026-02-27 07:03:00 +07:00

README.md

Yii2 Organization Chart Widget

Easily add Google Visualization OrgChart to your Yii2 application.

Screen Shot

Install

The preferred way to install this extension is through composer.

Either run

composer require kongoon/yii2-orgchart

Usage

To use this widget, insert the following code into a view file:

use kongoon\orgchart\OrgChart;

echo OrgChart::widget([
    'data' => [
            [['v' => 'Mike', 'f' => '<img src="https://placeholdit.imgix.net/~text?txtsize=20&txt=Mike&w=120&h=150" /><br  /> <strong>Mike</strong><br  />The President'],'', 'The President'],
            [['v' => 'Jim', 'f' => '<img src="https://placeholdit.imgix.net/~text?txtsize=20&txt=Jim&w=120&h=150" /><br  /><strong>Jim</strong><br  />The Test'],'Mike', 'VP'],
            [['v' => 'ทดสอบ', 'f' => '<img src="https://placeholdit.imgix.net/~text?txtsize=20&txt=ทดสอบ&w=120&h=150" /><br  /><strong>ทดสอบ</strong><br  />The Test'], 'Mike', ''],
            [['v' => 'Bob', 'f' => '<img src="https://placeholdit.imgix.net/~text?txtsize=20&txt=Bob&w=120&h=150" /><br  /><strong>Bob</strong><br  />The Test'], 'Jim', 'Bob Sponge'],
            [['v' => 'Caral', 'f' => '<img src="https://placeholdit.imgix.net/~text?txtsize=20&txt=Caral&w=120&h=150" /><br  /><strong>Caral</strong><br  />The Test'], 'Mike', 'Caral Title'],

    ]
]);