Skip to content

Instantly share code, notes, and snippets.

@bogsio
Created July 23, 2014 17:01
Show Gist options
  • Select an option

  • Save bogsio/3ef56b2db46d9ce9829a to your computer and use it in GitHub Desktop.

Select an option

Save bogsio/3ef56b2db46d9ce9829a to your computer and use it in GitHub Desktop.
TPT2 - Adding authorization
class TodoListResource(ModelResource):
class Meta:
authentication = SessionAuthentication()
authorization = AuthorizationByUser()
queryset = TodoList.objects.all()
resource_name = 'list'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment