{% extends "admin/base_site.html" %}
{% load i18n admin_urls static %}

{% block extrahead %}
{{ block.super }}
{{ media }}
<script src="{% static 'admin/js/cancel.js' %}" async></script>
{% endblock %}

{% block extrastyle %}
{{ block.super }}
<link rel="stylesheet" type="text/css" href="{% static "admin/css/forms.css" %}">
<link rel="stylesheet" type="text/css" href="{% static "admin/css/confirmation.css" %}">
{% endblock %}

{% block bodyclass %}{{ block.super }} app-{{ opts.app_label }} model-{{ opts.model_name }} change-confirmation{% endblock %}

{% block breadcrumbs %}
<div class="breadcrumbs">
    <a href="{% url 'admin:index' %}">{% trans 'Home' %}</a>
    &rsaquo; <a href="{% url 'admin:app_list' app_label=opts.app_label %}">{{ opts.app_config.verbose_name }}</a>
    {% if not add %}
    &rsaquo; <a href="{% url opts|admin_urlname:'changelist' %}">{{ opts.verbose_name_plural|capfirst }}</a>
    &rsaquo; <a href="{% url opts|admin_urlname:'change' object_id|admin_urlquote %}">{{ object_name|truncatewords:"18" }}</a>
    &rsaquo; {% trans 'Confirm change' %}
    {% else %}
    &rsaquo; {% trans 'Confirm add' %}
    {% endif %}
</div>
{% endblock %}

{% block content %}
{% if add or save_as_new %}
<p>{% blocktrans with escaped_object=object %}Are you sure you want to add the {{ model_name }}?{% endblocktrans %}</p>
{% else %}
<p>{% blocktrans with escaped_object=object %}Are you sure you want to change the {{ model_name }} "{{ object_name }}"?{% endblocktrans %}</p>
{% endif %}

{% include "include/change_data.html" %}

<form {% if form.is_multipart %}enctype="multipart/form-data" {% endif %} method="post" {% if add %}action="{% url opts|admin_urlname:'add'%}" {% else %}action="{% url opts|admin_urlname:'change' object_id|admin_urlquote %}" {% endif %}>{% csrf_token %}
    <div class="hidden" id="hidden-form">
        {{form.as_p}}
        {% for cleared_field in cleared_fields %}
        <input type="checkbox" name="{{ cleared_field }}-clear" checked>
        {% endfor %}
        {% for formset in formsets %}
        {{ formset.as_p }}
        {% endfor %}
    </div>
    {% if is_popup %}<input type="hidden" name="{{ is_popup_var }}" value="1">{% endif %}
    {% if to_field %}<input type="hidden" name="{{ to_field_var }}" value="{{ to_field }}">{% endif %}
    {% if form.is_multipart %}<input type="hidden" name="_confirmation_received" value="True">{% endif %}
    <div class="submit-row">
        <input type="submit" value="{% trans 'Yes, I’m sure' %}" name="{{ submit_name }}">
        <p class="deletelink-box">
            <a href="#" class="button cancel-link">{% trans "No, continue to edit" %}</a>
        </p>
    </div>
</form>
{% endblock %}
