You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been trying to figure out how to add a field that displays all the models that a Role has been applied to. I know it should be roughly the inverse of the MorphToMany used in my User resource:
However, I'm failing dismally at trying to see how to define a field for "things that this Role is applied to" since obviously it doesn't have a single class name that I can give it. I can see the records in the assigned_roles table that represent this linkage, but can't spot a corresponding relation in Bouncer to use in the MorphToMany.
I'm hoping that you have a better understanding of this!
The text was updated successfully, but these errors were encountered:
I've been trying to figure out how to add a field that displays all the models that a
Role
has been applied to. I know it should be roughly the inverse of theMorphToMany
used in myUser
resource:However, I'm failing dismally at trying to see how to define a field for "things that this Role is applied to" since obviously it doesn't have a single class name that I can give it. I can see the records in the
assigned_roles
table that represent this linkage, but can't spot a corresponding relation in Bouncer to use in theMorphToMany
.I'm hoping that you have a better understanding of this!
The text was updated successfully, but these errors were encountered: