Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 0
Authorization
Mattia Roccoberton edited this page Jun 4, 2023
·
1 revision
Authorization is provided setting the option authorization_class to a class that inherits from the Authorization and that overrides the allowed? class method:
authorization_class: Admin::PermsWhile the Perms class could be like this:
moduleAdminclassPerms < TinyAdmin::Plugins::Authorizationclass << selfdefallowed?(user,action,param=nil)returnfalseifaction == :page && param == 'stats'trueendendendend