How to natively handle multiple values for one parameter name separated by ampersand? #1736
-
|
Hi, I'm trying to build some filters where we pass multiple values for one parameter name. I was hoping to represent the values in the query string as follows I traced through the code and found that However, since it inherits from |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
You're looking for a
For model usage see |
Beta Was this translation helpful? Give feedback.
You're looking for a
MultipleChoiceFilter, which does this by default.https://django-filter.readthedocs.io/en/stable/ref/filters.html#django_filters.filters.MultipleChoiceFilter
For model usage see
ModelMultipleChoiceFilter: https://django-filter.readthedocs.io/en/stable/ref/filters.html#django_filters.filters.ModelMultipleChoiceFilter