Skip to content
Discussion options

You must be logged in to vote

You should be able to use the following too:

/**
 * Determine if this resource is available for navigation.
 *
 * @param  \Illuminate\Http\Request  $request
 * @return bool
 */
public static function availableForNavigation(Request $request)
{
    return $request->user()->hasRole('admin'); 
}

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@jandante
Comment options

@crynobone
Comment options

Answer selected by jandante
@jandante
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants