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
Instead of getter methods, create a query method, bound only to model (not query builder).
Something like this:
awaitUser.messages(userId)// here you can start chaining query builder methods for the related query
It seems to be more consistent with other methods.
One thing though, to avoid the risk of method collisions (with scopes) I think that the scopes proxy should be removed. They should be available only when using the query builder.
I started working on this one and bumped into an issue with the way how queries are built and what they're returning. This is a case mostly for BelongsToMany which joins the pivot table and selects the foreign key from that table.
I'd like to avoid adding unnecessary data to the results, however, this can't be done in a decent way for this feature. I decided to wait a moment and rethink the architecture for this. Quite possibly, I should finish #5 first.
This would generate the
getMessages(id)
method which generates a query to theMessage
model with corresponding WHERE statement.The text was updated successfully, but these errors were encountered: