From eaae4f96d1f8838f0f2668435d037faef5cc3dec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9DNyymix=E2=80=9D?= Date: Thu, 19 Jun 2025 18:19:20 +0300 Subject: [PATCH] Add autocomplete cover in admin --- gallery/admin.py | 1 + 1 file changed, 1 insertion(+) diff --git a/gallery/admin.py b/gallery/admin.py index e671ec5..13bd513 100644 --- a/gallery/admin.py +++ b/gallery/admin.py @@ -71,6 +71,7 @@ class AlbumAdmin(admin.ModelAdmin): list_editable = ('is_public',) readonly_fields = ['cover_preview'] change_form_template = "admin/gallery/album/change_form.html" + autocomplete_fields = ['cover'] def get_urls(self): """Add custom upload route to admin."""