| 1 |
# -*- coding: utf-8 -*- |
| 2 |
|
| 3 |
from __future__ import absolute_import, unicode_literals |
| 4 |
|
| 5 |
from rest_framework.mixins import ListModelMixin, RetrieveModelMixin |
| 6 |
from rest_framework.viewsets import ViewSetMixin |
| 7 |
|
| 8 |
from drf_haystack.generics import HaystackGenericAPIView |
| 9 |
|
| 10 |
|
| 11 |
class HaystackViewSet(RetrieveModelMixin, ListModelMixin, ViewSetMixin, HaystackGenericAPIView): |
| 12 |
""" |
| 13 |
The HaystackViewSet class provides the default ``list()`` and |
| 14 |
``retrieve()`` actions with a haystack index as it's data source. |
| 15 |
""" |
| 16 |
pass |