Edit links view
This commit is contained in:
@ -37,7 +37,7 @@ from .books.books import (
|
||||
from .books.books import update_book_from_remote
|
||||
from .books.edit_book import EditBook, ConfirmEditBook
|
||||
from .books.editions import Editions, switch_edition
|
||||
from .books.links import AddFileLink
|
||||
from .books.links import BookFileLinks, AddFileLink
|
||||
|
||||
# landing
|
||||
from .landing.about import about, privacy, conduct
|
||||
|
@ -10,6 +10,15 @@ from bookwyrm import forms, models
|
||||
|
||||
|
||||
# pylint: disable=no-self-use
|
||||
class BookFileLinks(View):
|
||||
"""View all links"""
|
||||
|
||||
def get(self, request, book_id):
|
||||
"""view links"""
|
||||
book = get_object_or_404(models.Edition, id=book_id)
|
||||
return TemplateResponse(request, "book/edit_links.html", {"book": book})
|
||||
|
||||
|
||||
@method_decorator(login_required, name="dispatch")
|
||||
@method_decorator(
|
||||
permission_required("bookwyrm.edit_book", raise_exception=True), name="dispatch"
|
||||
|
Reference in New Issue
Block a user