datocms / product-roadmap

This project is now discontinued. For feature requests, please use our community forum.
https://community.datocms.com/
19 stars 1 forks source link

filter model missing $notin #157

Closed mxdi9i7 closed 5 years ago

mxdi9i7 commented 5 years ago

Is your feature request related to a problem? Please describe. I'm not able to filter through a collection (ex: articles) by excluding the results from a list of ids. I think that's a very common use case in a feature such as:

  1. explicitly to not return one or more documents in a model
  2. avoid repeated documents in separate instances of a model

Describe the solution you'd like I think its useful for ID model filters to have an $notin filter type, so I can exclude results based on an array of IDs

Describe alternatives you've considered I have been keeping a pool of all existing docs id on the client side in-memory and looping through each document while checking if the pool contains what's returned to make sure none is repetitive on the same page within different instances of models.

Additional context N/A

matjack1 commented 5 years ago

This is now live!