This variant of 'FilterSet' will convert a 'django.forms.ValidationError',
which wouldn't be handled by DRF, to a
'rest_framework.exceptions.ValidationError', which would be.
Signed-off-by: Stephen Finucane <stephen@that.guru>
[dja: commit message]
Signed-off-by: Daniel Axtens <dja@axtens.net>
from django.contrib.auth.models import User
from django.core.exceptions import ValidationError
from django.db.models import Q
-from django_filters import FilterSet
+from django_filters.rest_framework import FilterSet
from django_filters import IsoDateTimeFilter
from django_filters import ModelMultipleChoiceFilter
from django.forms import ModelMultipleChoiceField as BaseMultipleChoiceField