Fix IP address interface validation

This commit is contained in:
Jeremy Stretch
2021-03-17 16:44:34 -04:00
parent 54f1308f50
commit c83f51496d
3 changed files with 19 additions and 16 deletions

View File

@@ -74,7 +74,8 @@
<td>Assignment</td>
<td>
{% if object.assigned_object %}
<span><a href="{{ object.assigned_object.parent.get_absolute_url }}">{{ object.assigned_object.parent }}</a> ({{ object.assigned_object }})</span>
<a href="{{ object.assigned_object.parent_object.get_absolute_url }}">{{ object.assigned_object.parent_object }}</a> /
<a href="{{ object.assigned_object.get_absolute_url }}">{{ object.assigned_object }}
{% else %}
<span class="text-muted">&mdash;</span>
{% endif %}
@@ -86,7 +87,7 @@
{% if object.nat_inside %}
<a href="{% url 'ipam:ipaddress' pk=object.nat_inside.pk %}">{{ object.nat_inside }}</a>
{% if object.nat_inside.assigned_object %}
(<a href="{{ object.nat_inside.assigned_object.parent.get_absolute_url }}">{{ object.nat_inside.assigned_object.parent }}</a>)
(<a href="{{ object.nat_inside.assigned_object.parent_object.get_absolute_url }}">{{ object.nat_inside.assigned_object.parent_object }}</a>)
{% endif %}
{% else %}
<span class="text-muted">None</span>