igoole like dashboard for your application. move/remove/save/minimize portlets can be done.


Yii 1.1.6 or above
Download and extract dashboard_v_1.0.zip
Copy extracted dashboard folder to extensions directory
// In your view page do followings $obj = $this->widget('application.extensions.dashboard.dashboard', array( 'divColumns' => array('column1', 'column2', 'column3'),// Css class names of DIV columns 'dashHeader' => array('show'=>true, 'title'=>'Dashboard')// Dashboard header options )) // Adding portlets to each column // These column1,column2,column3 css classes are defined in dasboard/assests/css/dasboard.css // You can define your own columns and assign here also define them in above "divColumns" array as well // EXAMPLE 1 // ===================== <div class="column1"> <?php $obj->addPortlet('feeds', 'Feeds', 'Feeds Data');// portlet id, name, content <?php $obj->addPortlet('news', 'News', 'News Data'); </div> <div class="column2"> <?php $obj->addPortlet('shopping', 'Shopping','Shopping Data'); <?php $obj->addPortlet('hits', 'Hits','Hits Data'); </div> <div class="column3"> <?php $obj->addPortlet('weather', 'Weather', 'Whether Data'); <?php $obj->addPortlet('traffic', 'Traffic','Traffic Data')); </div> <?php $obj->end()// Closing widget // EXAMPLE 2 - Using render partial // ================================ <div class="column1"> <?php $obj->addPortlet('feeds', 'Feeds', 'FEEDS PORTAL');// portlet id, name, content <?php $obj->addPortlet('news', 'News', $this->renderPartial('_news',false,true)); </div> <div class="column2"> <?php $obj->addPortlet('shopping', 'Shopping', $this->renderPartial('_chart',false,true)); <?php $obj->addPortlet('hits', 'Hits', $this->renderPartial('_grid_view',false,true)); </div> <div class="column3"> <?php $obj->addPortlet('weather', 'Weather', '28 C Colombo'); <?php $obj->addPortlet('traffic', 'Traffic', $this->renderPartial('_meter',false,true)); </div> <?php $obj->end()// Closing widget // Thats all // Note: This dashboard save user selected portlets in a cookie for 30 days. Hope to save them in a db in future releases.
Download and extract dashboard_demo.zip
Copy dashboard_demo folder to web root and set Yii framework path in index.php
Now run http://localhost/dashboard_demo/index.php
1) How these charts were genarated?
Using jqplot chart library
2) How to adjust the width of containers?
Just change columns width in dasboard/assests/css/dasboard.css
3) My css changes were not applied
Just clear assests folder and run again
Total 9 comments
Hi,
Today I checked it with bootstrap and there is a issue with setting dialog, it will not display anything, only blank box is displayed.I think you too have the same issue? I`m looking forward to fix it.
Thanks Aruna
this ext have a conflict with bootstrap, how to make it work together
Hi scoob.junior,
Thanks for your comments.If you want to pass back end data to portlet use render partial as below.
<?php $obj->addPortlet('hits', 'Hits', $this->renderPartial('_grid_view',array('backend_data'=>$backend_data),true));?>Thanks
Aruna
Thanks for this excellent ext
I've got a small cms with a fixed dashboard and would like to use this ext, however, I'd like to ask you how do we render widgets instead of views in the content, like
$obj->addPortlet('feeds', 'Feeds', <<my_widget_backend_feeds_in_here>> )
Thanks in advance
=))
Thank you for the wonderful extension...It worked out for me...
Hi Sundarban,
Attached the demo project(dashboard_demo.zip) also. You can use it.
Thanks Aruna
Thank you for your help regarding example 1. Which was easy to implement As well as It will be better if u will provide render file also.It will be easy for beginners.
Thanks in advance Sundar
Hi Sundarban,
I have not included actual render partial files(_news,_chart etc..) there. It is just to mention how to use this extension with render partial.You can create your own view file and include using render partial.Try with EXAMPLE 1, there is no render partials.
Thanks Aruna
Hello, I am try this new extension. Well I had gone through the guide. But I can understand one thing. There is a
<?php $obj->addPortlet('news', 'News', $this->renderPartial('_news',false,true));?>and similar for other form like _chart,_grid_view,_meter?
where renderpartial form name is _news. I could not get display even after changing the name of form. How to display this in our local form?
Thanks in Advance Sundar
Leave a comment
Please login to leave your comment.