group_resource.py 391 B

12345678910111213
  1. # -*- coding: utf-8 -*-
  2. from __future__ import unicode_literals
  3. from tastypie.resources import ModelResource
  4. from api.utils.jwt_authentication import JWTAuthentication
  5. from django.contrib.auth.models import Group
  6. '''
  7. '''
  8. class GroupResource(ModelResource):
  9. class Meta:
  10. queryset = Group.objects.all()
  11. always_return_data = True
  12. authentication = JWTAuthentication()