mirror of
https://github.com/django/django.git
synced 2025-07-05 18:29:11 +00:00
newforms-admin: Removed 'filters' admin_list templatetag, folding its output into the change_list.html template
git-svn-id: http://code.djangoproject.com/svn/django/branches/newforms-admin@4353 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
f9019a7a7b
commit
2ea6cdbd9d
@ -21,7 +21,18 @@
|
||||
<div class="module{% if cl.has_filters %} filtered{% endif %}" id="changelist">
|
||||
{% block search %}{% search_form cl %}{% endblock %}
|
||||
{% block date_hierarchy %}{% date_hierarchy cl %}{% endblock %}
|
||||
{% block filters %}{% filters cl %}{% endblock %}
|
||||
|
||||
{% block filters %}
|
||||
{% if cl.has_filters %}
|
||||
<div id="changelist-filter">
|
||||
<h2>{% trans 'Filter' %}</h2>
|
||||
{% for spec in cl.filter_specs %}
|
||||
{% filter cl spec %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
{% block result_list %}{% result_list cl %}{% endblock %}
|
||||
{% block pagination %}{% pagination cl %}{% endblock %}
|
||||
</div>
|
||||
|
@ -1,7 +0,0 @@
|
||||
{% load admin_list %}
|
||||
{% load i18n %}
|
||||
{% if cl.has_filters %}<div id="changelist-filter">
|
||||
<h2>{% trans 'Filter' %}</h2>
|
||||
{% for spec in cl.filter_specs %}
|
||||
{% filter cl spec %}
|
||||
{% endfor %}</div>{% endif %}
|
@ -264,7 +264,3 @@ search_form = register.inclusion_tag('admin/search_form.html')(search_form)
|
||||
def filter(cl, spec):
|
||||
return {'title': spec.title(), 'choices' : list(spec.choices(cl))}
|
||||
filter = register.inclusion_tag('admin/filter.html')(filter)
|
||||
|
||||
def filters(cl):
|
||||
return {'cl': cl}
|
||||
filters = register.inclusion_tag('admin/filters.html')(filters)
|
||||
|
Loading…
x
Reference in New Issue
Block a user