From 37148c5127fd2eaa036181a99bd8eeca3ed7fe29 Mon Sep 17 00:00:00 2001 From: Hugh Rundle Date: Mon, 1 Nov 2021 10:26:17 +1100 Subject: [PATCH] display isni bio with existing author name If an existing author has an isni on record and it matches an author from the isni api call, display the isni short description to aid with identifying the appropriate author. --- bookwyrm/templates/book/edit/edit_book.html | 4 ++++ bookwyrm/templatetags/utilities.py | 12 ++++++++++++ bookwyrm/views/books/edit_book.py | 3 +++ 3 files changed, 19 insertions(+) diff --git a/bookwyrm/templates/book/edit/edit_book.html b/bookwyrm/templates/book/edit/edit_book.html index 104cef4d..2ce6067f 100644 --- a/bookwyrm/templates/book/edit/edit_book.html +++ b/bookwyrm/templates/book/edit/edit_book.html @@ -1,6 +1,7 @@ {% extends 'layout.html' %} {% load i18n %} {% load humanize %} +{% load utilities %} {% block title %}{% if book %}{% blocktrans with book_title=book.title %}Edit "{{ book_title }}"{% endblocktrans %}{% else %}{% trans "Add Book" %}{% endif %}{% endblock %} @@ -75,6 +76,9 @@

{% blocktrans with book_title=match.book_set.first.title %}Author of {{ book_title }}{% endblocktrans %}

+

+ {{ author.existing_isnis|get_isni_bio:match }} +

{% endfor %}