2021-09-06 16:48:57 +00:00
|
|
|
{% extends 'lists/layout.html' %}
|
2021-02-28 02:48:10 +00:00
|
|
|
{% load i18n %}
|
2021-01-31 20:07:54 +00:00
|
|
|
|
2021-12-30 20:34:21 +00:00
|
|
|
{% block breadcrumbs %}
|
|
|
|
<nav class="breadcrumb subtitle" aria-label="breadcrumbs">
|
|
|
|
<ul>
|
|
|
|
<li><a href="{% url 'lists' %}">{% trans "Lists" %}</a></li>
|
|
|
|
<li><a href="{% url 'list' list.id %}">{{ list.name|truncatechars:30 }}</a></li>
|
|
|
|
<li class="is-active">
|
|
|
|
<a href="#" aria-current="page">
|
|
|
|
{% trans "Curate" %}
|
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</nav>
|
|
|
|
{% endblock %}
|
2021-04-24 13:49:30 +00:00
|
|
|
|
2021-12-30 20:34:21 +00:00
|
|
|
{% block panel %}
|
|
|
|
<section class="block">
|
|
|
|
<h2 class="title is-4">{% trans "Pending Books" %}</h2>
|
2021-04-24 13:49:30 +00:00
|
|
|
|
2021-01-31 20:07:54 +00:00
|
|
|
{% if not pending.exists %}
|
2021-12-30 20:34:21 +00:00
|
|
|
<p><em>{% trans "You're all set!" %}</em></p>
|
2021-01-31 20:07:54 +00:00
|
|
|
{% else %}
|
2021-04-24 13:49:30 +00:00
|
|
|
|
2021-12-30 20:34:21 +00:00
|
|
|
<div class="columns">
|
2021-01-31 20:07:54 +00:00
|
|
|
{% for item in pending %}
|
2021-12-30 20:34:21 +00:00
|
|
|
{% with book=item.book %}
|
|
|
|
<div class="column">
|
|
|
|
<div class="columns is-mobile">
|
|
|
|
<a
|
|
|
|
class="column is-cover"
|
|
|
|
href="{{ book.local_path }}"
|
|
|
|
aria-hidden="true"
|
|
|
|
>
|
|
|
|
{% include 'snippets/book_cover.html' with cover_class='is-w-xs-mobile is-w-s is-h-xs-mobile is-h-s' size_mobile='xsmall' size='small' %}
|
|
|
|
</a>
|
2021-04-24 13:49:30 +00:00
|
|
|
|
2021-12-30 20:34:21 +00:00
|
|
|
<div class="column ml-3">
|
|
|
|
{% include 'snippets/book_titleby.html' %}
|
2021-04-24 13:49:30 +00:00
|
|
|
|
2021-12-30 20:34:21 +00:00
|
|
|
<p>
|
|
|
|
{% trans "Suggested by" %}
|
2021-04-24 13:49:30 +00:00
|
|
|
|
2021-12-30 20:34:21 +00:00
|
|
|
<a href="{{ item.user.local_path }}">
|
|
|
|
{{ item.user.display_name }}
|
|
|
|
</a>
|
|
|
|
</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2021-04-24 13:49:30 +00:00
|
|
|
|
2021-12-30 20:34:21 +00:00
|
|
|
<div class="column is-narrow">
|
|
|
|
<div class="field has-addons">
|
|
|
|
<form class="control" method="POST" action="{% url 'list-curate' list.id %}">
|
|
|
|
{% csrf_token %}
|
|
|
|
<input type="hidden" name="item" value="{{ item.id }}">
|
|
|
|
<input type="hidden" name="approved" value="true">
|
|
|
|
<button type="submit" class="button">{% trans "Approve" %}</button>
|
|
|
|
</form>
|
|
|
|
<form class="control" method="POST" action="{% url 'list-curate' list.id %}">
|
|
|
|
{% csrf_token %}
|
|
|
|
<input type="hidden" name="item" value="{{ item.id }}">
|
|
|
|
<input type="hidden" name="approved" value="false">
|
|
|
|
<button type="submit" class="button is-danger is-light">{% trans "Discard" %}</button>
|
|
|
|
</form>
|
2021-04-24 13:49:30 +00:00
|
|
|
</div>
|
2021-12-30 20:34:21 +00:00
|
|
|
</div>
|
|
|
|
{% endwith %}
|
2021-01-31 20:07:54 +00:00
|
|
|
{% endfor %}
|
2021-12-30 20:34:21 +00:00
|
|
|
</div>
|
2021-01-31 20:07:54 +00:00
|
|
|
{% endif %}
|
|
|
|
</section>
|
|
|
|
{% endblock %}
|