Closed dipankarmaikap closed 2 years ago
Thanks @dipankarmaikap! We'll look into this.
Internal note: we're tracking this in Jira under BH-1190.
@dipankarmaikap just noting that it's possible to query by author now. Taxonomy filtering is coming in the near future. We'll update you here when that's available.
Work in progress on documenting taxonomy queries/filtering: https://github.com/wpengine/headless-docs/pull/104
Internal link for our reference: https://wpengine.atlassian.net/browse/MTKA-1310
ACM now supports filtering by taxonomy, slug and author as requested.
Upgrade to the latest version of ACM, then you can:
Enter a slug for your entry in the sidebar, such as "custom".
Use this query to fetch a post by its slug (for a model named "rabbit"):
{
rabbitBy(slug: "custom") {
title
}
}
Change the author from the post sidebar if needed.
Use this query to fetch entries by author (for a model named 'rabbits'):
{
rabbits(where: {authorName: "local"}) {
edges {
node {
title
}
}
}
}
Is your feature request related to a problem? Please describe.
Currently there is really no option available for filter for the models created.
Describe the solution you'd like
In wp graphql its offers all the above mentions option for all the native post types, Something similar.
Describe alternatives you've considered
There is really no real alternative for this one thing would be to fetch all the data and then filter in the front-end.