diff --git a/netbox/templates/ipam/aggregate.html b/netbox/templates/ipam/aggregate.html index ae79e9b66..d2dfe8888 100644 --- a/netbox/templates/ipam/aggregate.html +++ b/netbox/templates/ipam/aggregate.html @@ -40,14 +40,7 @@

{% block title %}{{ aggregate }}{% endblock %}

{% include 'inc/created_updated.html' with obj=aggregate %} - {% if show_available is not None %} -
-
- Show available - Hide available -
-
- {% endif %} + {% include 'ipam/inc/toggle_available.html' %}
{% custom_links aggregate %}
diff --git a/netbox/templates/ipam/inc/toggle_available.html b/netbox/templates/ipam/inc/toggle_available.html new file mode 100644 index 000000000..21d734d2d --- /dev/null +++ b/netbox/templates/ipam/inc/toggle_available.html @@ -0,0 +1,9 @@ +{% load helpers %} +{% if show_available is not None %} +
+
+ Show available + Hide available +
+
+{% endif %} diff --git a/netbox/templates/ipam/prefix.html b/netbox/templates/ipam/prefix.html index 43b723553..56267786f 100644 --- a/netbox/templates/ipam/prefix.html +++ b/netbox/templates/ipam/prefix.html @@ -53,14 +53,7 @@

{% block title %}{{ prefix }}{% endblock %}

{% include 'inc/created_updated.html' with obj=prefix %} - {% if show_available is not None %} -
-
- Show available - Hide available -
-
- {% endif %} + {% include 'ipam/inc/toggle_available.html' %}
{% custom_links prefix %}