Guest User

Untitled

a guest
Sep 20th, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. class UserSerializer(serializers.ModelSerializer):
  2. """ A serializer class for the User model """
  3. class Meta:
  4. # Specify the model we are using
  5. model = User
  6. # Specify the fields that should be made accessible.
  7. # Mostly it is all fields in that model
  8. fields = ('id', 'first_name', 'last_name', 'username',
  9. 'password', 'is_active', 'is_superuser')
Add Comment
Please, Sign In to add comment