From 12ba5e61f837a3e456ac91c07c5e94a5cc65811c Mon Sep 17 00:00:00 2001 From: Yohan Boniface Date: Sun, 17 Dec 2023 12:20:30 +0100 Subject: [PATCH] Allow to edit pictogram categories from admin list --- umap/admin.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/umap/admin.py b/umap/admin.py index 22796267..34ae2321 100644 --- a/umap/admin.py +++ b/umap/admin.py @@ -17,8 +17,17 @@ class MapAdmin(admin.GISModelAdmin): list_filter = ("share_status",) +class PictogramAdmin(admin.ModelAdmin): + list_display = ( + "name", + "category", + ) + list_editable = ("category",) + list_filter = ("category",) + + admin.site.register(Map, MapAdmin) admin.site.register(DataLayer) -admin.site.register(Pictogram) +admin.site.register(Pictogram, PictogramAdmin) admin.site.register(TileLayer, TileLayerAdmin) admin.site.register(Licence)