mirror of
https://github.com/ajurna/cbwebreader.git
synced 2025-12-06 22:27:19 +00:00
* Adding black, isort, and flake8 to pytest * Applying black, flake8, and isort to codebase
31 lines
750 B
Python
31 lines
750 B
Python
from django.contrib import admin
|
|
|
|
from comic.models import ComicBook, ComicPage, ComicStatus, Directory, Setting
|
|
|
|
|
|
@admin.register(Setting)
|
|
class SettingAdmin(admin.ModelAdmin):
|
|
list_display = ("name", "value")
|
|
|
|
|
|
@admin.register(ComicBook)
|
|
class ComicBookAdmin(admin.ModelAdmin):
|
|
list_display = ["file_name", "date_added"]
|
|
search_fields = ["file_name"]
|
|
|
|
|
|
@admin.register(ComicPage)
|
|
class ComicPageAdmin(admin.ModelAdmin):
|
|
list_display = ("Comic", "index", "page_file_name", "content_type")
|
|
list_filter = ["Comic"]
|
|
|
|
|
|
@admin.register(ComicStatus)
|
|
class ComicStatusAdmin(admin.ModelAdmin):
|
|
list_display = ["user", "comic", "last_read_page", "unread"]
|
|
|
|
|
|
@admin.register(Directory)
|
|
class DirectoryAdmin(admin.ModelAdmin):
|
|
pass
|