diff options
author | Parker Berberian <pberberian@iol.unh.edu> | 2018-02-19 20:58:15 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@opnfv.org> | 2018-02-19 20:58:15 +0000 |
commit | 907b5d1be1657301e4701d0d08235db16e7d31de (patch) | |
tree | baf5b387fac5ddc48279c8be0c0c03f59cea1802 /src/api/views.py | |
parent | 21a025644865678c7ce9ef60a5cbec07e86f737c (diff) | |
parent | 86cfa9015a8e09544bc7b1547ec329a567f4c66d (diff) |
Merge "Expose Limited User Info Through API"
Diffstat (limited to 'src/api/views.py')
-rw-r--r-- | src/api/views.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/api/views.py b/src/api/views.py index c16d57d..b873ef1 100644 --- a/src/api/views.py +++ b/src/api/views.py @@ -16,6 +16,7 @@ from rest_framework import viewsets from rest_framework.authtoken.models import Token from api.serializers import * +from account.models import UserProfile from booking.models import Booking from dashboard.models import Resource, Server, ResourceStatus @@ -45,6 +46,10 @@ class NotifierViewSet(viewsets.ModelViewSet): queryset = Notifier.objects.none() serializer_class = NotifierSerializer +class UserViewSet(viewsets.ModelViewSet): + queryset = UserProfile.objects.all() + serializer_class = UserSerializer + @method_decorator(login_required, name='dispatch') class GenerateTokenView(View): def get(self, request, *args, **kwargs): |