solved Add Panel to Dashboard

sbhadauria
@sbhadauria
9 years ago
129 posts
I have created a new panel for dashboard but it is not displaying.

Code:

jrCore_register_module_feature('jrCore', 'dashboard_panel', 'djMix', 'today licenses', 'djMix_dashboard_panels');


function djMix_dashboard_panels($panel)
{
$out = array(
'title' => 10
);
return ($out) ? $out : false;
}


Is I am doing anything wrong?

updated by @sbhadauria: 02/14/16 01:56:49AM
michael
@michael
9 years ago
7,714 posts
That should be enough. Just to make sure its all in the correct locations, I have used your code and created a module that uses it.

Download the attached djMix.zip file attached to this post.

* Upload it to your jamroom system.
* ACP -> SITE -> DJ MIX -> INFO -> ACTIVATE (save changes)

That will activate the module on your site.

Once its activated the dashboard panel will be an option for the admin user to add to the dashboard.

So as the admin user:
DASHBOARD -> CUSTOMIZE -> Number of Rows (add more than are currently visible so you have empty spaces.)

Then click on one of the empty dashboard boxes that contains an ?

You will see your module "DJ Mix" so click on the "Today License" and it will show in that dashboard panel.

--edit--
I've updated the docs to include the part about extending the amount of panels that can be customized:

"Documentation: Dashboard Panels"
https://www.jamroom.net/the-jamroom-network/documentation/development/3156/dashboard-panel
zip
djMix.zip  •  3KB



updated by @michael: 11/09/15 10:18:07PM
sbhadauria
@sbhadauria
9 years ago
129 posts
Thanks it's working

Tags