esoftslimited/yii2-dashboard
Composer 安装命令:
composer require esoftslimited/yii2-dashboard
包简介
Yii2 Dashboard is a module that allows you to create and manage dashboards using custom layouts and panels.
关键字:
README 文档
README
Yii2 Dashboard is a module that allows you to create and manage admin dashboards using custom layouts and panels.
Installation
Yii2-dashboard is designed to work out of the box, meaning that installation requires minimal steps. Only one configuration step should be taken and you are ready to have a dynamic dashboard on your Yii2 website.
1. Download
The preferred way to install this extension is through composer.
Either run
php composer.phar require --prefer-dist esoftslimited/yii2-dashboard "*"
or add
"esoftslimited/yii2-dashboard": "*"
to the require section of your composer.json file.
Usage
2. Configure
Add following lines to your main configuration file:
NOTE: Make sure that you don't have
dashboardcomponent ormoduleconfiguration in your config files. otherwise this step will override it
'modules' => [ 'dashboard' => [ 'class' => 'esoftslimited\dashboard\Module', ], ],
Where do I go now?
You have Yii2-dashboard installed. Now you can start adding panels on to your dashboard using this method
\Yii::$app->dashboard->addPanel($name,$view,$section);
The addPanel() function accepts 3 parameters
$name; /** name of the panel **/ $view; /** content of the panel **/ $section; /** section where the panel will be displayed**/
NOTE: You can add as many panel as you wish
Playing around with layouts?
The dashboard component allows custom layouts using the following function
\Yii::$app->dashboard->setLayout(String $layout);
Displaying The panels?
On your admin/dashboad view invoke
\Yii::$app->dashboard->display;
to display your panels
Full Example?
On your dashboard view add the following
$layout='<div class="row"><div class="col-md-8">{stats}</div> <div class="col-md-4">{test2}</div></div></div>'; \Yii::$app->dashboard->setLayout($layout); \Yii::$app->dashboard->addPanel('{stats}',$testView); \Yii::$app->dashboard->addPanel('test2','<dic class="row">Example</div>'); //\Yii::$app->dashboard->addPanel('test3','View3','left'); \Yii::$app->dashboard->display;
What next after this? (Our Roadmap)
The module is still on dev we are hoping to achieve a dynamic easy to use plugin
- Add module hooks,where modules will be able to 'inject' thier panels to the dashboard on-the-fly
- Allow using yii\widgets\Block on layouts
- Utilize cache for enhacing performace
- Add hooks for allowing draggable and saving user settings to the database
- Add many useful functions on dashboard component;
- Design default module for diplaying dashboard that is flexible and extensible
- Organize this ToDo in order of priority
- Relax and develop
esoftslimited/yii2-dashboard 适用场景与选型建议
esoftslimited/yii2-dashboard 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 72 次下载、GitHub Stars 达 0, 最近一次更新时间为 2015 年 08 月 28 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「extension」 「yii2」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 esoftslimited/yii2-dashboard 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 esoftslimited/yii2-dashboard 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 esoftslimited/yii2-dashboard 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
A custom URL rule class for Yii 2 which allows to create translated URL rules
The Yii2 extension uses jQuery jquery.carousel-1.1.min.js and makes image carousel from php array of structure defined.
TYPO3 CMS extension to create gallery content element with preset crop ratios and pagination
UI Kit 3 Extension for Yii2
Adds more BBCode
Define your own css rule-sets for the TYPO3 CMS backend.
统计信息
- 总下载量: 72
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 15
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2015-08-28