{% extends 'generic/object.html' %} {% load helpers %} {% load interface_profiles %} {% block content %} {# While the job runs, poll this page and swap in the refreshed result until the job finishes #}
{% if not object.is_finished %}
{% if object.dry_run %}Calculating changes{% else %}Synchronizing interfaces{% endif %}… This page updates automatically.
{% elif not object.is_completed %} {% elif object.dry_run and paginator.count %} {% elif paginator.count %} {% else %} {% endif %}

Synchronization

Role {{ object.interface_role|linkify }}
Mode {% if object.dry_run %} Dry run {% else %} Commit {% endif %}
Status {% badge object.get_status_display bg_color=object.get_status_color %}
User {{ object.job.user|placeholder }}
Completed {{ object.job.completed|isodatetime|placeholder }}
Interfaces {% if object.interface_count is not None %} {{ object.interface_count }} assigned, {{ paginator.count }} changed {% else %} {{ ''|placeholder }} {% endif %}
Job {% if perms.core.view_job %} #{{ object.job.pk }} {% else %} #{{ object.job.pk }} {% endif %}
{% if object.is_completed and paginator.count %}

{% if object.dry_run %}Proposed Changes{% else %}Changes{% endif %}

{% for row in rows %} {% for attribute in row.attributes %} {% if forloop.first %} {% with interface=row.change.interface %} {% endwith %} {% endif %} {% endfor %} {% endfor %}
Device Interface Attribute Before After
{% if interface %}{{ interface.device|linkify }}{% else %}{{ row.change.device_name }}{% endif %} {% if interface %}{{ interface|linkify:"name" }}{% else %}{{ row.change.interface_name }}{% endif %} {{ attribute.label|bettertitle }} {% sync_value attribute.old %} {% sync_value attribute.new %}
{% include 'inc/paginator.html' with paginator=paginator page=page %}
{% endif %}
{% endblock %}