Piki is a minimal wiki
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

admin.py 463B

1234567891011121314151617
  1. from django.contrib import admin
  2. from simple_history.admin import SimpleHistoryAdmin
  3. from .models import PikiPage
  4. class PikiPageAdmin(SimpleHistoryAdmin):
  5. list_display = ('rel_path', 'tags', 'deleted')
  6. history_list_display = ('rel_path', 'tags', 'deleted')
  7. search_fields = ('rel_path', 'tags', )
  8. list_filter = (
  9. ('deleted', admin.BooleanFieldListFilter),
  10. )
  11. ordering = ["rel_path"]
  12. admin.site.register(PikiPage, PikiPageAdmin)