Closed Brhmts closed 7 years ago
Hi @Brhmts,
You can add permissions in one of two ways, firstly you can add a permission to a group which can be done like this:
This will allow or deny a specific permission against a group, users who inherit this group will also inherit all permissions as well.
This takes three parameters:
Usage:
$this->ion_auth_acl->add_permission_to_group($group_id, $permission_id, $value);
This will allow or deny a specific permission against a user regardless of whether the group permission is set to allow or deny.
This takes three parameters:
Usage:
$this->ion_auth_acl->add_permission_to_user($user_id, $permission_id, $value);
If you want to do the reverse of what's above then follow the following, these should be pretty self-explanatory:
$this->ion_auth_acl->remove_permission_from_group($group_id, $permission_id);
$this->ion_auth_acl->remove_permission_from_user($user_id, $permission_id);
If you need any further help then just give me a shout
Hi Steve , First Thank you for your effort with this usefull library .
When we add a permission
perm_key => any key perm_name => class\method
value=> false or true
How should fill the add permission form?
trying solve data logic .. Could you give an example to save permission ? for example user group id =1 cant save users , users/create