Version 3 with Tenancy + Spatie's Permission package
Is it possible to have a Tenancy and each tenant have their own "Roles & Permissions"?
I already implemented the tenancy part but currently I have an issue with the "unique" index of the tables related to the Roles and Permissions.
What I'm trying to achieve is each tenant must have their own Roles and Permissions.
2 Replies
https://spatie.be/docs/laravel-permission/v6/basic-usage/teams-permissions
When creating a role you can pass the team_id as an optional parameter
The second option is what you are looking for as its a role created for the specified team (id.)
Hence why it can have the same name on different teams because different teams can have a role with a name that some other teams may have already used.
Thank you @๖ۣۜζ͜͡Redicated