Files
@ 3d2465eff823
Branch filter:
Location: conntrackt/conntrackt/templates/conntrackt/entity_detail.html - annotation
3d2465eff823
1.2 KiB
text/html
CONNT-4: Added buttons for adding new entities to specific location in a project.
0e5abbd2d3d6 ad556f8e81bd 202776b43053 90fac7c6abb9 ad556f8e81bd ad556f8e81bd 202776b43053 ad556f8e81bd 202776b43053 ad556f8e81bd ad556f8e81bd ad556f8e81bd 202776b43053 df07ff9dfd85 202776b43053 202776b43053 202776b43053 202776b43053 202776b43053 202776b43053 202776b43053 ad556f8e81bd 0d7adadf08a3 ad556f8e81bd ad556f8e81bd ad556f8e81bd 202776b43053 202776b43053 | {% extends "conntrackt/base.html" %}
{# For html_link. #}
{% load conntrackt_tags %}
{% block content %}
{# Use a bit shorter variable names. #}
{% with project=entity.project location=entity.location %}
{% if entity %}
<h1>{{entity.name}}</h1>
<dl>
<dt>Project</dt><dd>{% html_link project.name 'project' project.id %}</dd>
<dt>Location</dt><dd>{{location.name}}</dd>
<dt>Incoming communications</dt><dd><ul class="unstyled">{% for interface in entity.interface_set.all %}
{% for communication in interface.destination_set.all %}
<li>{{communication.source}} - {{communication.protocol}}: {{communication.port}}</li>
{% endfor %}{% endfor %}</ul></dd>
<dt>Outgoing communications</dt><dd><ul class="unstyled">{% for interface in entity.interface_set.all %}
{% for communication in interface.source_set.all %}
<li>{{communication.destination}} - {{communication.protocol}}: {{communication.port}}</li>
{% endfor %}{% endfor %}</ul></dd>
<dt>iptables rules</dt><dd><pre>{{ entity_iptables }}</pre>{% html_link 'Download' 'entity_iptables' entity.id class="btn btn-primary input-small" %}</dd>
</dl>
{% endif %}
{% endwith %}
{% endblock %}
|