From 78db9902b0f0000aaf21b97c20dba51a2e4bc360 Mon Sep 17 00:00:00 2001 From: Aroy-Art Date: Sat, 19 Oct 2024 23:59:41 +0200 Subject: [PATCH] Add: search fields to file admin page for submission files --- archivist/apps/files/admin.py | 1 + 1 file changed, 1 insertion(+) diff --git a/archivist/apps/files/admin.py b/archivist/apps/files/admin.py index 0afef7d..4c45a4d 100644 --- a/archivist/apps/files/admin.py +++ b/archivist/apps/files/admin.py @@ -9,6 +9,7 @@ from .models import Metadata_Files, Submission_File, User_Profile_Images, User_B class Submission_FileAdmin(admin.ModelAdmin): list_display = ('id', 'file_link', 'date_added', 'file_hash', 'file',) + search_fields = ['file_name', 'file_hash'] def file_link(self, obj): url = reverse("admin:files_submission_file_change", args=[obj.id])