{% extends 'base/layout.html' %} {% block title %}{{ device }} - Interface comparison{% endblock %} {% block header %} {{ block.super }} {% endblock %} {% block content %}

{% if templates_count == interfaces_count %} The device and device type have the same number of interfaces. {% else %} The device and device type have different number of interfaces.
Device: {{ interfaces_count }}
Device type: {{ templates_count }} {% endif %}

{% csrf_token %} {% for template, interface in comparison_items %} {% if template %} {% else %} {% endif %} {% endfor %}
Device type Actions
Name Type
{% if interface and template.name != interface.name %} {{ template.name }} {% else %} {{ template.name }} {% endif %} {{ template.type_display }} {% if not interface %} {% endif %}
     
{% for template, interface in comparison_items %} {% if interface %} {% else %} {% endif %} {% endfor %}
Device Actions
Name Type
{% if template and template.name != interface.name %} {{ interface.name }} {% else %} {{ interface.name }} {% endif %} {{ interface.type_display }} {% if not template %} {% endif %} {% if template and template.name != interface.name %} {% endif %}
       
{% endblock %}