mirror of
https://github.com/lemeow125/Ivy-Backend.git
synced 2024-11-17 06:39:26 +08:00
13 lines
410 B
Python
13 lines
410 B
Python
from rest_framework import viewsets
|
|
from .serializers import UserSerializer
|
|
from django.contrib.auth.models import User
|
|
from rest_framework.permissions import IsAuthenticated
|
|
|
|
# Create your views here.
|
|
|
|
|
|
class UserListViewSet(viewsets.ModelViewSet):
|
|
permission_classes = [IsAuthenticated]
|
|
http_method_names = ['get']
|
|
serializer_class = UserSerializer
|
|
queryset = User.objects.all()
|