2024-10-05 11:55:55 +02:00
|
|
|
from django.contrib import admin
|
2024-10-21 07:20:37 +02:00
|
|
|
from simple_history.admin import SimpleHistoryAdmin
|
2024-10-05 11:55:55 +02:00
|
|
|
|
2024-10-21 07:20:37 +02:00
|
|
|
from .models import PikiPage
|
|
|
|
|
|
|
|
|
|
|
|
class PikiPageAdmin(SimpleHistoryAdmin):
|
|
|
|
list_display = ('rel_path', 'tags', 'deleted')
|
|
|
|
history_list_display = ('rel_path', 'tags', 'deleted')
|
|
|
|
search_fields = ('rel_path', 'tags', )
|
|
|
|
list_filter = (
|
|
|
|
('deleted', admin.BooleanFieldListFilter),
|
2024-10-21 17:29:49 +02:00
|
|
|
('other_perms_read', admin.BooleanFieldListFilter),
|
|
|
|
('other_perms_write', admin.BooleanFieldListFilter),
|
2024-10-21 07:20:37 +02:00
|
|
|
)
|
|
|
|
ordering = ["rel_path"]
|
|
|
|
|
|
|
|
|
|
|
|
admin.site.register(PikiPage, PikiPageAdmin)
|