X-Git-Url: https://git.mdrn.pl/redakcja.git/blobdiff_plain/cd330644503795289b6402e3622b5768b2ebed6c..2dd9e6498b5e0bd5c0bd882db02be9768c34c019:/src/documents/admin.py 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']}