{% load i18n thumbnail %}
<div class="well text-center volume-item {% if volume.pk in user_have_volumes %}user-have-it{% endif %} {% if volume.pk in user_wishlisted_volumes %}user-wishlisted-it{% endif %}">
    <div class="badges">
        {% if volume.pk in user_have_volumes %}
        <a href="{% url "volume.have_it" volume.pk %}" data-pjax="v{{ volume.pk }}" pjax-nopush pjax-messages>
            <span class="badge badge-success badge-have-it">
                <i class="glyphicon glyphicon-ok"></i>
            </span>
        </a>
        {% else %}
        <a href="{% url "volume.have_it" volume.pk %}" data-pjax="v{{ volume.pk }}" pjax-nopush pjax-messages>
            <span class="badge badge-have-it">
                <i class="glyphicon glyphicon-ok"></i>
            </span>
        </a>
        <a href="{% url "volume.wishlist" volume.pk %}" data-pjax="v{{ volume.pk }}" pjax-messages pjax-nopush>
            <span class="badge badge-wishlist-it {% if volume.pk in user_wishlisted_volumes %}badge-warning{% endif %}">
                <i class="glyphicon glyphicon-star"></i>
            </span>
        </a>
        {% endif %}
    </div>
    <div class="text-center volume-content">
        {% if volume.for_review and user.is_staff %}
        <span class="label label-warning">{% trans "Requires review" %}</span>
        {% endif %}
        {% if volume.number %}
        <div><strong>#{{ volume.number }}</strong></div>
        {% endif %}
        {% if volume.name %}
        <div><strong>{{ volume.name }}</strong></div>
        {% endif %}
        {% if volume.release_date %}
        <div>{{ volume.release_date|date:"F Y" }}</div>
        {% endif %}
    </div>
    <img src="{% thumbnail volume.cover 150x150 %}" class="volume-cover max-width-80" />
    {% if USER_IS_STAFF and USER_CONFIG.show_admin_links %}
        <div class="admin">
            <a class="btn btn-info btn-xs"
               href="{% url 'admin:manga_volume_change' volume.pk %}">
               {% trans "Edit in admin" %}</a>
        </div>
    {% endif %}
</div>
