laravel-acl icon indicating copy to clipboard operation
laravel-acl copied to clipboard

Assign Permission & General How To

Open esolitos opened this issue 10 years ago • 1 comments

Hi, this package seems nice, but I can't figure out how to manage the permissions.

I saw that there are two tables acl_roles_permissions and acl_users_permissions but i'm unsure how to fill those, i don't see anything in the classes to add permissions. Do I have to implement it or am I missing something?

Thanks

esolitos avatar Jun 29 '14 11:06 esolitos

In documentation there isn't any description how you do. For manage permission and group you can use the method write in acl/src/VivifyIdeas/Acl/Manager.php. For example, add new permission with command Acl::createPermission('ID_PERMISSION', false, array('GET:/test/'), false, 'name permission') or for assign permission to user have to use Acl::assignPermission( $userId, $permissionId, $allowed = null, array $allowedIds = null, array $excludedIds = null )

abemiles2000 avatar Oct 05 '14 15:10 abemiles2000