New user can't see my custom module
I've been scouring the forums and I still can't figure out why the new user I created can't see my custom module called "Gallery".
Here's what I have in the "MY_FUEL_Modules.php" file:
$config['modules']['gallery'] = array(
'module_name' => 'Gallery',
'instructions' => 'Here you can manage the gallery images',
'sanitize_images' => TRUE,
'model_name' => 'galleryImages_model',
'permission' => 'Gallery'
);
If I go into the permission section of the admin, I created a permission called "Manage gallery". If i give my new user this permission, they still don't see the "Gallery" module on the left hand navigation. What am I missing?
Comments
If you log in that new user and print out the value of $this->fuel_auth->get_permissions() do you see that permission associated with that user?
The left menu is generated in the fuel/modules/fuel/views/_blocks/fuel_header.php file and around line 60 or so it does a permission check using the has_permission method on Fuel_auth:
if (($this->fuel_auth->has_permission($key)) || $key == 'dashboard')
if (($this->fuel_auth->has_permission($key)) || $key == 'dashboard') { echo 'key = '.$key; } else { echo 'bad key ='.$key; }
it prints out "bad key = gallery".
The reason I used "Manage gallery" is because when setting up a permission, if you hover over the name label it says something about using the word "Manage" for things to appear in the left nav. Can you explain that to me in more detail?