Files @ ce8399670e39
Branch filter:

Location: conntrackt/conntrackt/templates/admin/conntrackt/communication/change_list.html

branko
Implemented queryset for limitting selections for source/destination to a project/site in the admin site for Communication. Added customised admin class for more complex models.
{% extends "admin/change_list.html" %}
{% load i18n admin_static admin_list %}
{% load url from future %}
{% load admin_urls %}

{% block object-tools-items %}
            <li>
              <a href="{% url cl.opts|admin_urlname:'add' %}?{% if is_popup %}_popup=1{% endif %}{% if 'source__entity__location__id__exact' in cl.params %}&source__entity__location__id__exact={{ cl.params.source__entity__location__id__exact }}{% endif %}{% if 'source__entity__project__id__exact' in cl.params %}&source__entity__project__id__exact={{ cl.params.source__entity__project__id__exact }}{% endif %}" class="addlink">
                {% blocktrans with cl.opts.verbose_name as name %}Add {{ name }}{% endblocktrans %}
              </a>
            </li>
{% endblock %}