eager-load-pivot-relations
eager-load-pivot-relations copied to clipboard
Ability to use `loadCount`
Hello,
the package works great! It would be nice to have the chance to use loadCount
too, like we already use with
/ load
.
Currently if I try to use it to load count a pivot relationship, it just throws an error like this:
Call to undefined method App\Citizen::vehicles.registration()
Where registration
is the custom name of the pivot table.
@danilopolani can you show how you did it in your code?
Did you figure this out and could possible share code? Thank you
Ehy, sorry, this refers to an old project to which I no longer have access. If I'm right, I didn't find a valid solution tho :/