1 from django.contrib import admin
2 from philo.admin.base import EntityAdmin, TreeEntityAdmin
3 from philo.models import Node, Redirect, File
6 class NodeAdmin(TreeEntityAdmin):
10 class ViewAdmin(EntityAdmin):
14 class RedirectAdmin(ViewAdmin):
17 'fields': ('target', 'status_code')
20 list_display = ('target', 'status_code')
21 list_filter = ('status_code',)
24 class FileAdmin(ViewAdmin):
27 'fields': ('file', 'mimetype')
30 list_display = ('mimetype', 'file')
33 admin.site.register(Node, NodeAdmin)
34 admin.site.register(Redirect, RedirectAdmin)
35 admin.site.register(File, FileAdmin)