How to add permission check in pages?

so usually i use resource and policies, but now im working on pages, how do i add permission check? i tried this but it still openable through the url
protected static function shouldRegisterNavigation(): bool {
return auth()->user()->can("View report");
}
protected static function shouldRegisterNavigation(): bool {
return auth()->user()->can("View report");
}
0 Replies
No replies yetBe the first to reply to this messageJoin