Method |
Description |
|
__call ( string $method, array $arguments = [] ) : mixed |
Magic __call method to handle dynamic methods. |
|
assignRole ( integer $roleId = null ) : boolean |
Assigns the given role to the user. |
|
can ( string $permission, array $arguments = [] ) : boolean |
Check if user has the given permission. |
|
canAtLeast ( array $permissions ) : boolean |
Check if user has at least one of the given permissions. |
|
getPermissions ( ) : array | null |
Get all user role permissions. |
|
getRoles ( ) : array | null |
Get all user roles. |
|
isRole ( string $slug ) : boolean |
Checks if the user has the given role. |
|
revokeAllRoles ( ) : boolean |
Revokes all roles from the user. |
|
revokeRole ( integer $roleId = '' ) : boolean |
Revokes the given role from the user. |
|
roles ( ) : Illuminate\Database\Eloquent\Model |
Users can have many roles. |
|
syncRoles ( array $roleIds ) : boolean |
Syncs the given role(s) with the user. |
|