Fix book importing
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
from django.contrib import admin
|
||||
|
||||
from books.models import Author, Book
|
||||
from books.models import Author, Book, Page
|
||||
|
||||
from scrobbles.admin import ScrobbleInline
|
||||
|
||||
@ -8,11 +8,22 @@ from scrobbles.admin import ScrobbleInline
|
||||
@admin.register(Author)
|
||||
class AuthorAdmin(admin.ModelAdmin):
|
||||
date_hierarchy = "created"
|
||||
list_display = ("name", "openlibrary_id")
|
||||
list_display = (
|
||||
"name",
|
||||
"openlibrary_id",
|
||||
"bio",
|
||||
"wikipedia_url",
|
||||
)
|
||||
ordering = ("-created",)
|
||||
search_fields = ("name",)
|
||||
|
||||
|
||||
@admin.register(Page)
|
||||
class PageAdmin(admin.ModelAdmin):
|
||||
date_hierarchy = "created"
|
||||
list_filter = ("book",)
|
||||
|
||||
|
||||
@admin.register(Book)
|
||||
class BookAdmin(admin.ModelAdmin):
|
||||
date_hierarchy = "created"
|
||||
|
||||
Reference in New Issue
Block a user