Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

django rest framework viewset

class UserViewSet(viewsets.ModelViewSet):
    """
    A viewset for viewing and editing user instances.
    """
    serializer_class = UserSerializer
    queryset = User.objects.all()
Source by www.django-rest-framework.org #
 
PREVIOUS NEXT
Tagged: #django #rest #framework #viewset
ADD COMMENT
Topic
Name
6+2 =