Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[bug 740013] Update admin change_list.html template for 1.4.3.

  • Loading branch information...
commit 2e2daad6d1814398f7334417454a58e463f49eac 1 parent b99c68c
@rlr rlr authored
Showing with 13 additions and 18 deletions.
  1. +13 −18 templates/admin/change_list.html
View
31 templates/admin/change_list.html
@@ -1,17 +1,18 @@
{% extends "admin/base_site.html" %}
+{% load i18n admin_static admin_list %}
+{% load url from future %}
+{% load admin_urls %}
{# NOTE: This is a copy of django/contrib/admin/templates/admin/change_list.html
that adds the "novalidate" attribute to the #changelist-form. Our
monkeypatch to form fields break this form by adding required attributes
in a way that makes this form unusable. #}
-{% load adminmedia admin_list i18n %}
-{% load url from future %}
{% block extrastyle %}
{{ block.super }}
- <link rel="stylesheet" type="text/css" href="{% admin_media_prefix %}css/changelists.css" />
+ <link rel="stylesheet" type="text/css" href="{% static "admin/css/changelists.css" %}" />
{% if cl.formset %}
- <link rel="stylesheet" type="text/css" href="{% admin_media_prefix %}css/forms.css" />
+ <link rel="stylesheet" type="text/css" href="{% static "admin/css/forms.css" %}" />
{% endif %}
{% if cl.formset or action_form %}
{% url 'admin:jsi18n' as jsi18nurl %}
@@ -42,19 +43,13 @@
{% block bodyclass %}change-list{% endblock %}
{% if not is_popup %}
- {% block breadcrumbs %}
- <div class="breadcrumbs">
- <a href="../../">
- {% trans "Home" %}
- </a>
- &rsaquo;
- <a href="../">
- {{ app_label|capfirst }}
- </a>
- &rsaquo;
- {{ cl.opts.verbose_name_plural|capfirst }}
- </div>
- {% endblock %}
+{% block breadcrumbs %}
+<div class="breadcrumbs">
+<a href="{% url 'admin:index' %}">{% trans 'Home' %}</a>
+&rsaquo; <a href="{% url 'admin:app_list' app_label=cl.opts.app_label %}">{{ app_label|capfirst|escape }}</a>
+&rsaquo; {{ cl.opts.verbose_name_plural|capfirst }}
+</div>
+{% endblock %}
{% endif %}
{% block coltype %}flex{% endblock %}
@@ -66,7 +61,7 @@
<ul class="object-tools">
{% block object-tools-items %}
<li>
- <a href="add/{% if is_popup %}?_popup=1{% endif %}" class="addlink">
+ <a href="{% url cl.opts|admin_urlname:'add' %}{% if is_popup %}?_popup=1{% endif %}" class="addlink">
{% blocktrans with cl.opts.verbose_name as name %}Add {{ name }}{% endblocktrans %}
</a>
</li>
Please sign in to comment.
Something went wrong with that request. Please try again.