kongoon/yii2-orgchart

适用于Yii Framework 2.0的Google Visualization OrgChart

安装次数: 2,193

依赖项: 0

建议者: 0

安全: 0

星标: 3

关注者: 2

分支: 4

公开问题: 1

类型:yii2-extension

0.0.2 2016-05-23 09:14 UTC

This package is auto-updated.

Last update: 2024-09-12 02:50:02 UTC


README

轻松将Google Visualization OrgChart添加到您的Yii2应用程序中。

Screen Shot

安装

安装此扩展的首选方式是通过composer

运行以下命令之一

composer require kongoon/yii2-orgchart

用法

要使用此小部件,将以下代码插入视图文件中

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'],

    ]
]);