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

Handle where filter for prisma relations #17

Merged
merged 2 commits into from
Jul 20, 2021
Merged

Conversation

foyarash
Copy link
Contributor

For prisma, allows the following where filter

{"posts.title": {"$cont": "Hello"}}

to

{
  posts: {
    some: {
      title: {
        contains: "Hello"
      }
    }
  }
}

This works when adding the relation to the manyRelations field of the PrismaAdapter, like so: manyRelations: ['posts']

@foyarash foyarash requested review from tlenclos and baptadn January 22, 2021 11:27
@zuhair-naqvi
Copy link

Anything blocking merging this PR?

@baptadn baptadn merged commit 2cfa1d9 into master Jul 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants