vyuldashev / nova-permission

A Laravel Nova tool for Spatie's laravel-permission library
https://novapackages.com/packages/vyuldashev/nova-permission
419 stars 217 forks source link

Use other guard than Nova uses #152

Open danielschweiger opened 3 years ago

danielschweiger commented 3 years ago

I have an own guard "admin" for Nova. With the tool I want to manage the users who are using "web" guard and login at my jetstream dashbaord. How can I tell the tool to use individuael guard?

In Role.php the tool get's the guard here:

$userResource = Nova::resourceForModel(getModelForGuard($this->guard_name));

The result is

App\Nova\Admin 

It should be

App\Nova\User

in my case.

Would be cool if one could configure this on tool initialization. Even better would be the tool could handle multiple guards.