Inxentas Posted February 10, 2022 Share Posted February 10, 2022 My goal is to add a tab at the top of the admin named "tools" under which I want to install a few custom modules. For the Tools tab, I used a page with a ProcessList (so it visually looks like the Templates page). This works perfectly for superusers, but I cannot for the life of me find out how to allow other roles then the superuser to access these pages. I've tried allowing the "admin" templates to be viewed by these Roles, but that doesn't seem to work. Is this actually possible? Link to comment Share on other sites More sharing options...
BillH Posted February 10, 2022 Share Posted February 10, 2022 If a user has permission to access one of the modules under your Tools menu, the Tools menu should automatically appear for that user. So, in your module, you might have something like this: public static function getModuleInfo() { return array( 'title' => 'Test Module', 'summary' => 'Module to test permissions', 'version' => 1, 'permission' => 'test-permission', 'page' => array( 'name' => 'test-module', 'parent' => 'tools', 'title' => 'Test Module' ) ); } Then if the module is installed and the user has a role with 'test-permission', the Tools menu (and of course the Test Module item) should appear. 2 Link to comment Share on other sites More sharing options...
Inxentas Posted February 10, 2022 Author Share Posted February 10, 2022 Super, thank you! I couldn't find it in the Process module documentation, but that makes a lot of sense. I'm almost embarrased ? 1 Link to comment Share on other sites More sharing options...
BillH Posted February 11, 2022 Share Posted February 11, 2022 I don't know if it's in the documentation anywhere. I just somehow knew from experience! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now