From a81901f9fe749e3a2b0d9a46e48374b928bed0fa Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Mon, 3 May 2021 11:20:43 -0700 Subject: [PATCH] Re-adds "manually add book" link --- bookwyrm/templates/search/book.html | 20 ++++++++++++-------- bookwyrm/urls.py | 2 +- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/bookwyrm/templates/search/book.html b/bookwyrm/templates/search/book.html index 53aadb63e..84c2fafea 100644 --- a/bookwyrm/templates/search/book.html +++ b/bookwyrm/templates/search/book.html @@ -57,18 +57,22 @@ {% endif %} -{% if not remote %}

{% if request.user.is_authenticated %} - - {% trans "Load results from other catalogues" %} - + {% if not remote %} + + {% trans "Load results from other catalogues" %} + + {% else %} + + {% trans "Manually add book" %} + + {% endif %} {% else %} - - {% trans "Log in to import or add books." %} - + + {% trans "Log in to import or add books." %} + {% endif %}

-{% endif %} {% endblock %} diff --git a/bookwyrm/urls.py b/bookwyrm/urls.py index 5412378e6..14fe476d4 100644 --- a/bookwyrm/urls.py +++ b/bookwyrm/urls.py @@ -272,7 +272,7 @@ urlpatterns = [ ), re_path(r"%s/edit/?$" % book_path, views.EditBook.as_view()), re_path(r"%s/confirm/?$" % book_path, views.ConfirmEditBook.as_view()), - re_path(r"^create-book/?$", views.EditBook.as_view()), + re_path(r"^create-book/?$", views.EditBook.as_view(), name="create-book"), re_path(r"^create-book/confirm?$", views.ConfirmEditBook.as_view()), re_path(r"%s/editions(.json)?/?$" % book_path, views.Editions.as_view()), re_path(