Skip to content

Instantly share code, notes, and snippets.

@akshar-raaj
Created July 7, 2019 19:21
Show Gist options
  • Select an option

  • Save akshar-raaj/8ab0926c3fb7c7d2aaa75223b65cb4de to your computer and use it in GitHub Desktop.

Select an option

Save akshar-raaj/8ab0926c3fb7c7d2aaa75223b65cb4de to your computer and use it in GitHub Desktop.
Search view
from rest_framework import generics
from .models import Question
from .serializers import QuestionSerializer
class QuestionsAPIView(generics.ListCreateAPIView):
queryset = Question.objects.all()
serializer_class = QuestionSerializer
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment