{{{
modelAAdmin(admin.ModelAdmin)
list_filter = ('filter_a',)
modelBAdmin(admin.ModelAdmin)
list_filter = ('filter_b',)
}}}
If I navigate to modelA admin page first and than move to modelB admin
page the filters defined in modelA are displayed instead of the modelB's
one.
Making a selection on the wrongly displayed filter appends ** ?e=1** and
no error displayed.
This also happen if there is more than two model admin classes.
--
Ticket URL: <https://code.djangoproject.com/ticket/29456>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* status: new => closed
* resolution: => needsinfo
Comment:
Hi @grpoundblue.
This needs extra info as is — I can't reproduce it. Can you provide a
minimal steps to reproduce or test project that demonstrates the issue?
Thanks.
--
Ticket URL: <https://code.djangoproject.com/ticket/29456#comment:1>
Comment (by grpoundblue):
Finally I was able to get rid of this weird behavior, honestly without
investigating further. However I put this here hopefully someone can
figure it out the exact cause.
I had a custom template for change_list.html like below, the motivation
was to increase performance in page loading :
{{{
PROJECT_HOME/myapp/templates/admin/myapp/change_list.html
}}}
The file's content was :
{{{
{% extends "admin/change_list.html" %}
{% load admin_list i18n cache %}
{% block filters %}
<!-- BETTER FILTER, date doesn't change a lot -->
{% cache 300 admin_filters request.GET.items request.path
request.user.username %}
{% if cl.has_filters %}
<div id="grp-filters" class="grp-module grp-filter testTEST">
<h2>{% trans 'Filter' %}</h2>
{% for spec in cl.filter_specs %}{% admin_list_filter cl spec
%}{% endfor %}
</div>
{% endif %}
{% endcache %}
{% endblock %}
}}}
So I just removed this custom template.
--
Ticket URL: <https://code.djangoproject.com/ticket/29456#comment:2>
* resolution: needsinfo => invalid
--
Ticket URL: <https://code.djangoproject.com/ticket/29456#comment:3>