Grouping Modules in the admin sidebar
Hi Admin,
Is there a way where-in we can group certain modules under the left sidebar of the admin panel. A more user friendly way of displaying certain sections of the website.
Like suppose we have 2 custom modules History page, Team, Management Team all to be displayed under collapsible About section.
Thanks.
Comments
// Site... Dashboard will always be there $config['nav']['site'] = array( 'dashboard' => lang('module_dashboard'), 'pages' => lang('module_pages'), 'blocks' => lang('module_blocks'), 'navigation' => lang('module_navigation'), 'tags' => lang('module_tags'), 'categories' => lang('module_categories'), 'assets' => lang('module_assets'), 'sitevariables' => lang('module_sitevariables') ); // My modules... if set to empty array, then it will automatically include all in MY_fuel_modules.php $config['nav']['modules'] = array(); // Tools $config['nav']['tools'] = array(); // Manage $config['nav']['manage'] = array( 'users' => lang('module_users'), 'permissions' => lang('module_permissions'), 'manage/cache' => lang('module_manage_cache'), 'logs' => lang('module_manage_activity'), 'settings' => lang('module_manage_settings'), );
Additionally, there is a
$config['nav_auto_arrange'] = TRUE;
parameter you can set in MY_fuel.php which will give you some more flexibility in the ordering if set to FALSE.Will this overwrite also handle the permission being set for individual user?
I tried to implement your solution by adding the below line But I received the below error: Can you suggest an alternative or may be I missed out on something. This error is displayed in the left sidebar of the admin panel. Below the error, I got one single module entry titled as 'Array' and linked to http://localhost/FUEL-CMS-master/admin/My Group .
I got what the code does but just wanted to know if there is a way to achieve a collapsible head under which certain modules could be grouped same as Site, Modules, Tools, Manage titles.
Thanks.
$nav['my_group'] = array('healthcare' => 'healthcare', 'benefits' => 'benefits');
unset($config['nav']['modules']);
$config['nav_auto_arrange'] = TRUE;