Skip to content
Advertisement

Tag: tinker

Laravel Eager Loading – Unexpected Behavior Difference between Code and Tiner

I am working on building a front-end for managing users / roles / permissions with the Spatie > Permissions package in the backend. A feature I am seeking to implement is selecting a Permission and having this selection then display all Users having the selected permission. Using php artisan tinker, I can use the statement: SpatiePermissionModelPermission::with(“roles.users”)->find(59);, with 59 representing the

Advertisement