{% extends "badger/base.html" %}
{% import "badger/includes/macros.html" as macros %}

{% set user = award.user %}
{% set award_url = request.build_absolute_uri(url('badger.views.award_detail', award.badge.slug, award.id)) %}
{% if award.image %}
    {% set image_url = award.image.url %}
{% elif badge.image %}
    {% set image_url = badge.image.url %}
{% else %}
    {# TODO: Put the URL for default badge image in settings #}
    {% set image_url = "/media/img/default-badge.png" %}
{% endif %}

{% block pageid %}award_delete{% endblock %}

{% block subcontent %}

<h1>{{ _('Badges: Delete Award') }}</h1>
<div class="column-container">
    <div class="column-strip">
        <a href="{{ badge.get_absolute_url() }}" class="image">{{ macros.badge_image(badge, MEDIA_URL, 256) }}</a>

        <form id="delete_award" method="POST" action="" enctype="multipart/form-data">
            {{ csrf() }}
            <input type="submit" class="button negative delete-badge" value="{{ _("Delete this award") }}">
        </form>
    </div>
    <div class="column-main">
        {% if badge.description %}
            <p>{{ badge.description }}</p>
        {% endif %}

        <section class="award span8">
            {% include "badger/includes/award_full.html" %}
        </section>
    </div>
</div>
{% endblock %}
