X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/cd330644503795289b6402e3622b5768b2ebed6c..14f2c24a604e36cad62ba9f6f8d71bf500f8e35a:/src/documents/admin.py?ds=inline diff --git a/src/documents/admin.py b/src/documents/admin.py index 21390a75..673a4684 100644 --- a/src/documents/admin.py +++ b/src/documents/admin.py @@ -2,9 +2,17 @@ # Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information. # from django.contrib import admin +import depot.models from . import models + +class SiteBookInline(admin.TabularInline): + model = depot.models.SiteBook + extra = 0 + + class BookAdmin(admin.ModelAdmin): + inlines = [SiteBookInline] list_display = ['title', 'public', '_published', '_new_publishable', 'project'] list_filter = ['public', '_published', '_new_publishable', 'project'] prepopulated_fields = {'slug': ['title']}