From 41b6bffa61fe78b75ffd7877e77fd511e3d5f9d2 Mon Sep 17 00:00:00 2001 From: jedi Date: Wed, 1 Nov 2023 01:50:00 +0100 Subject: [PATCH] add admin view for File model --- backend/files/admin.py | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 backend/files/admin.py diff --git a/backend/files/admin.py b/backend/files/admin.py new file mode 100644 index 0000000..ecdf983 --- /dev/null +++ b/backend/files/admin.py @@ -0,0 +1,11 @@ +from django.contrib import admin + +from .models import File + + +class FileAdmin(admin.ModelAdmin): + list_display = ('id', 'hash', 'mime_type', 'created_at', 'updated_at') + list_filter = ('id', 'hash', 'mime_type', 'created_at', 'updated_at') + + +admin.site.register(File, FileAdmin) \ No newline at end of file