django-rest-framework/rest_framework/authtoken/admin.py
2013-07-09 13:12:28 +01:00

12 lines
260 B
Python

from django.contrib import admin
from rest_framework.authtoken.models import Token
class TokenAdmin(admin.ModelAdmin):
list_display = ('key', 'user', 'created')
fields = ('user',)
ordering = ('-created',)
admin.site.register(Token, TokenAdmin)