Welcome Guest, Not a member yet? Register   Sign In
Announcing Shield: an Official Authentication library
#32

Great addition kilishan. I've been using Myth Auth for years.
Anyway, I'm not sure if this is a bug or this is how you designed it. I added user #1 to superadmin and checked the groups through getGroups()
PHP Code:
auth()->user()->getGroups() 

It returns the correct group

PHP Code:
Array
(
    [0] => superadmin



However, when I checked the permission, 

PHP Code:
auth()->user()->getPermissions() 
it doesn't give me the permissions indicated in the Permissions Matrix in Config/AuthGroups.php

PHP Code:
'superadmin' => [
    'admin.*',
    'users.*',
    'beta.*',
], 

I just want to be able to give the permissions to a group and the members of that group will also get those permissions. I can't find it in the documentation.

Thanks. Anyone can answer.
Reply


Messages In This Thread
RE: Announcing Shield: an Official Authentication library - by webmonster - 08-23-2022, 11:46 PM



Theme © iAndrew 2016 - Forum software by © MyBB