Answer the question
In order to leave comments, you need to log in
Is it possible to use Laratrust with Laravel Policies, or are they mutually exclusive?
The challenge is to implement user roles and groups. It is necessary to determine the rights to access sections and perform certain actions. Also, a group (or role) can influence the display of various information.
Initially, I wanted to use Laratrust for this, but the built-in policies are somehow more familiar.
It would be much more convenient to check for the presence of a role in a policy, but the laratrust trait overloads the can() method in the User model.
Tell me, how do you solve such problems with the differentiation of access rights? (:
Answer the question
In order to leave comments, you need to log in
I'm using bouncer . But, judging by the github, laratrust is also friends with gates and politicians (I still recommend bouncer).
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question