1
0
Fork 0

User shelves page

This commit is contained in:
Mouse Reeve 2020-03-16 17:29:37 -07:00
parent e1c598b7cf
commit ff1099d23e
6 changed files with 32 additions and 5 deletions

View file

@ -26,7 +26,7 @@
<div id="branding"><a href="/"><img id="logo" src="/static/images/logo-small.png" alt="BookWyrm"></img></a></div>
<ul class="menu">
<li><a href="/user/{{request.user.localname}}">Your shelves</a></li>
<li><a href="/user/{{request.user.localname}}/shelves">Your shelves</a></li>
<li><a href="/#feed">Updates</a></li>
<li><a href="/books">Discover Books</a></li>
</ul>

View file

@ -30,7 +30,7 @@
{% for book in shelf.books.all %}
<tr class="book-preview">
<td>
{% include 'snippets/book_cover.html' with book=book %}
{% include 'snippets/book_cover.html' with book=book size="small" %}
</td>
<td>
<a href="/book/{{ book.openlibrary_key }}">{{ book.title }}</a>

View file

@ -0,0 +1,14 @@
{% extends 'layout.html' %}
{% load fr_display %}
{% block content %}
{% include 'user_header.html' with user=user %}
{% for shelf in shelves %}
<div class="content-container">
<h2>{{ shelf.name }}</h2>
{% include 'snippets/shelf.html' with shelf=shelf ratings=ratings %}
</div>
{% endfor %}
{% endblock %}