Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filtering on Joined Models #35

Closed
calebkleveter opened this issue Jun 11, 2019 · 1 comment
Closed

Filtering on Joined Models #35

calebkleveter opened this issue Jun 11, 2019 · 1 comment
Labels
bug Something isn't working
Projects

Comments

@calebkleveter
Copy link
Member

Add support for filtering on joined models:

A.query(on: database).join(\.b).filter(\B.c == c).first()

Currently this will give this compiler error:

Cannot convert value of type 'ModelFilter<B>' to expected argument type 'ModelFilter<_>'
@calebkleveter calebkleveter added the bug Something isn't working label Jun 11, 2019
@calebkleveter calebkleveter added this to To Do in Vapor 4 via automation Jun 11, 2019
@tanner0101 tanner0101 mentioned this issue Jun 12, 2019
tanner0101 added a commit that referenced this issue Jun 12, 2019
* implement all operators, fixes  #37

* support joined models w/ filter operators, #35

* improve schema builder methods
@calebkleveter
Copy link
Member Author

Fixed by #38

Vapor 4 automation moved this from To Do to Done Jun 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Vapor 4
  
Done
Development

No branches or pull requests

1 participant