Closed kephren226 closed 2 years ago
Actually i found a solution I just extended the Role class and redifiened the availableforNavigation function
@kephren226 can you share relevant code snippets for how you achieved this?
Better still, can someone advise how this can be managed via configuration?
Cheers.
@kephren226 can you share relevant code snippets for how you achieved this?
Better still, can someone advise how this can be managed via configuration?
Cheers.
Hello what i have really done is extending the \Vyuldashev\NovaPermission\Role calss and redifining the availableForNavigation
so the class look like this
class DclRole extends \Vyuldashev\NovaPermission\Role { public static function availableForNavigation(Request $request) { return false; } }
And when adding to NovaServiceProvider.php tools function use your custom class as like this
\Vyuldashev\NovaPermission\NovaPermissionTool::make()->roleResource(\App\Nova\DclRole::class)
Hope it help
Is there a way to hide Role and Permission from nova menu I want the admin user to be able to select a role when creating users but i don't want him to be able to add role or permision so no need for the menus How can i achive this ?