{% extends "shatailadmin/base.html" %} {% load shatailimages_tags i18n shatailadmin_tags %} {% block titletag %}{% trans "Delete image" %}{% endblock %} {% block content %} {% trans "Delete image" as del_str %} {% include "shatailadmin/shared/header.html"
with title=del_str icon="image" %}

<div class="row row-flush nice-padding">
    <div class="col6">
        {% image image max-800x600 %}
    </div>
    <div class="col6">
        {% usage_count_enabled as uc_enabled %} {% if uc_enabled %}
        <div class="usagecount">
            <a href="{{ image.usage_url }}">{% blocktrans trimmed count usage_count=image.get_usage.count %}Used {{ usage_count }} time{% plural %}Used {{ usage_count }} times{% endblocktrans %}</a>
        </div>
        {% endif %}
        <p>
            {# This message will only appear in the singular, but we specify a plural so it can share the translation string with confirm_bulk_delete.html #} {% blocktrans trimmed count counter=1 %} Are you sure you want to delete this image? {% plural %} Are you
            sure you want to delete these images? {% endblocktrans %}
        </p>
        <form action="{% url 'shatailimages:delete' image.id %}" method="POST">
            {% csrf_token %}
            <input type="hidden" value="{{ next }}" name="next">
            <input type="submit" value="{% trans 'Yes, delete' %}" class="button serious" />
            <a href="{% url 'shatailimages:index' %}" class="button button-secondary">{% trans "No, don't delete" %}</a>
        </form>
    </div>
</div>
{% endblock %}