Skip to content

Is it possible to deep filter results #212

@lburns-civiconnect

Description

@lburns-civiconnect

As an example from my restaurant app, I have two collections: Menu Items and Allergens. Allergens is a many-1 relationship with Menu Items. I want to be able to fuzzy search Menu Items on the "name" field, while filtering for allergens. E.x. Give me "burgers" that don't contain "gluten".

The structure of my object would be:

{
  id: 1
  name: "hamburger"
  contains: [
    {
      id: 2,
      AllergenLabel: "Gluten",
     ...
    },
    ...
  ],
  ...
}

The regular Strapi API supports this by doing filters[contains][AllergenLabel][$ne]=Gluten
When I try the fuzzy search scoped filtering like filters[menu-items][contains][AllergenLabel][$ne]=Gluten it doesnt work.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions