{% extends "admin/change_form.html" %}
{% load i18n admin_modify admin_urls buttons %}

{% block object-tools %}
  {% if change %}
    {% if not is_popup %}
      <div class="admin-tools">

        <ul class="object-tools initialized">
          {% block object-tools-items %}
            {% url opts|admin_urlname:'history' original.pk|admin_urlquote as history_url %}
            <li>
              <a href="{% add_preserved_filters history_url %}" class="historylink">
                <i class="icon-time icon-alpha75"></i>
                {% trans "History" %}
              </a>
            </li>

            {% if has_add_permission %}
              <li>
                <a href="../../add/">
                  <i class="icon-plus-sign icon-alpha75"></i>
                  {% blocktrans with opts.verbose_name as name %}Add {{ name }}{% endblocktrans %}
                </a>
              </li>
            {% endif %}

          {% endblock %}
        </ul>

        {% include 'admin/sharing_links.html' %}
      </div>

      {% block extra_tools %}
      {% endblock %}
    {% endif %}
  {% endif %}
{% endblock %}


{% block submit_buttons_bottom %}{% save_buttons %}{% endblock %}
