It would be great to have some examples or documentation that show how to use where and loadWhere. Also how about loadRelatedWhere?
Also lets say I have roles and people and I have a given person record but I want role.name for that person. How would I go about getting that?
E.g. I have people, enquiries, roles. There's a pivot table enquiries_contacts which links these three entities. Now I'm getting a list of enquiries related to a people record, which I can do via related getter but I want to group the results by roles using the role.name attribute. How could I achieve this?
It would be great to have some examples or documentation that show how to use
where
andloadWhere
. Also how aboutloadRelatedWhere
?Also lets say I have
roles
andpeople
and I have a given person record but I wantrole.name
for that person. How would I go aboutgetting
that?E.g. I have
people
,enquiries
,roles
. There's a pivot tableenquiries_contacts
which links these three entities. Now I'm getting a list ofenquiries
related to apeople
record, which I can do viarelated
getter but I want to group the results byroles
using therole.name
attribute. How could I achieve this?