Improve the admin panel for navbar elements

Elements are now ordered by parent and weight.
The parent, link and weight are now displayed in the list.
fix issue #1
This commit is contained in:
Rodolphe Breard 2018-02-25 16:16:47 +01:00
parent 8862f67777
commit 884fd4579a

View file

@ -19,6 +19,8 @@ class ElementDescriptionInline(admin.StackedInline):
class ElementAdmin(admin.ModelAdmin):
list_display = ('__str__', 'parent', 'link', 'weight')
ordering = ('parent', 'weight')
inlines = [ElementDescriptionInline]