diff --git a/bookwyrm/templates/snippets/shelf.html b/bookwyrm/templates/snippets/shelf.html deleted file mode 100644 index 8cae29e63..000000000 --- a/bookwyrm/templates/snippets/shelf.html +++ /dev/null @@ -1,73 +0,0 @@ -{% load humanize %} -{% load i18n %} -{% load bookwyrm_tags %} -{% if books|length > 0 %} -
{% trans "Cover" %} | -{% trans "Title" %} | -{% trans "Author" %} | -{% trans "Published" %} | -{% trans "Shelved" %} | -{% trans "Started" %} | -{% trans "Finished" %} | -{% trans "External links" %} | {% if ratings %} -{% trans "Rating" %} | {% endif %} -|
---|---|---|---|---|---|---|---|---|---|
- {% include 'snippets/book_cover.html' with book=book size="small" %} - | -- {{ book.title }} - | -- {{ book.authors.first.name }} - | -- {% if book.first_published_date %}{{ book.first_published_date }}{% endif %} - | -- {{ book.created_date | naturalday }} - | - {% latest_read_through book user as read_through %} -- {{ read_through.start_date | naturalday |default_if_none:""}} - | -- {{ read_through.finish_date | naturalday |default_if_none:""}} - | -- {% trans "OpenLibrary" %} - | - {% if ratings %} -- {% include 'snippets/stars.html' with rating=ratings|dict_key:book.id %} - | - {% endif %} - {% if shelf.user == request.user %} -- {% include 'snippets/shelf_selector.html' with current=shelf %} - | - {% endif %} -
{% trans "This shelf is empty." %}
-{% if shelf.editable %} - -{% endif %} - -{% endif %} - diff --git a/bookwyrm/templates/user/shelf.html b/bookwyrm/templates/user/shelf.html index 189d28568..4c60258c9 100644 --- a/bookwyrm/templates/user/shelf.html +++ b/bookwyrm/templates/user/shelf.html @@ -1,5 +1,6 @@ {% extends 'user/user_layout.html' %} {% load bookwyrm_tags %} +{% load humanize %} {% load i18n %} {% block header %} @@ -63,7 +64,76 @@{% trans "Cover" %} | +{% trans "Title" %} | +{% trans "Author" %} | +{% trans "Shelved" %} | +{% trans "Started" %} | +{% trans "Finished" %} | + {% if ratings %}{% trans "Rating" %} | {% endif %} + {% if shelf.user == request.user %} + + {% endif %} +|
---|---|---|---|---|---|---|---|
+ {% include 'snippets/book_cover.html' with book=book size="small" %} + | ++ {{ book.title }} + | ++ {% include 'snippets/authors.html' %} + | ++ {{ book.created_date | naturalday }} + | + {% latest_read_through book user as read_through %} ++ {{ read_through.start_date | naturalday |default_if_none:""}} + | ++ {{ read_through.finish_date | naturalday |default_if_none:""}} + | + {% if ratings %} ++ {% include 'snippets/stars.html' with rating=ratings|dict_key:book.id %} + | + {% endif %} + {% if shelf.user == request.user %} ++ {% include 'snippets/shelf_selector.html' with current=shelf %} + | + {% endif %} +
{% trans "This shelf is empty." %}
+ {% if shelf.editable %} + + {% endif %} + + {% endif %} +