mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-11 04:07:39 +03:00
12 lines
260 B
Python
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)
|