diff --git a/netbox/templates/circuits/circuit.html b/netbox/templates/circuits/circuit.html index ec1369e1b..7b22c5d65 100644 --- a/netbox/templates/circuits/circuit.html +++ b/netbox/templates/circuits/circuit.html @@ -66,18 +66,7 @@ {% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='circuits:circuit_list' %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_left_page object %}
diff --git a/netbox/templates/circuits/provider.html b/netbox/templates/circuits/provider.html index 9434d99ec..4d35da0e6 100644 --- a/netbox/templates/circuits/provider.html +++ b/netbox/templates/circuits/provider.html @@ -52,18 +52,7 @@
{% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='circuits:provider_list' %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_right_page object %}
diff --git a/netbox/templates/circuits/providernetwork.html b/netbox/templates/circuits/providernetwork.html index 49f34e922..a5eac1f78 100644 --- a/netbox/templates/circuits/providernetwork.html +++ b/netbox/templates/circuits/providernetwork.html @@ -37,20 +37,9 @@ {% plugin_left_page object %}
-
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
{% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='circuits:providernetwork_list' %} + {% include 'inc/comments_panel.html' %} {% plugin_right_page object %}
diff --git a/netbox/templates/dcim/device.html b/netbox/templates/dcim/device.html index 162e201b1..72e42129c 100644 --- a/netbox/templates/dcim/device.html +++ b/netbox/templates/dcim/device.html @@ -210,18 +210,7 @@ {% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='dcim:device_list' %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_left_page object %}
diff --git a/netbox/templates/dcim/devicetype.html b/netbox/templates/dcim/devicetype.html index ad6853877..cd3da3efa 100644 --- a/netbox/templates/dcim/devicetype.html +++ b/netbox/templates/dcim/devicetype.html @@ -126,18 +126,7 @@
{% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='dcim:devicetype_list' %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_right_page object %}
diff --git a/netbox/templates/dcim/powerfeed.html b/netbox/templates/dcim/powerfeed.html index 0632cff4c..b4fb06081 100644 --- a/netbox/templates/dcim/powerfeed.html +++ b/netbox/templates/dcim/powerfeed.html @@ -182,18 +182,7 @@ {% endif %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_right_page object %} diff --git a/netbox/templates/dcim/rack.html b/netbox/templates/dcim/rack.html index 631dbf9f3..0a278f2d6 100644 --- a/netbox/templates/dcim/rack.html +++ b/netbox/templates/dcim/rack.html @@ -168,18 +168,7 @@ {% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='dcim:rack_list' %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% if power_feeds %}
diff --git a/netbox/templates/dcim/site.html b/netbox/templates/dcim/site.html index 201b24b61..1e50e7ba6 100644 --- a/netbox/templates/dcim/site.html +++ b/netbox/templates/dcim/site.html @@ -167,18 +167,7 @@
{% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='dcim:site_list' %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_left_page object %}
diff --git a/netbox/templates/extras/journalentry.html b/netbox/templates/extras/journalentry.html index 2862fb8bc..925d98b41 100644 --- a/netbox/templates/extras/journalentry.html +++ b/netbox/templates/extras/journalentry.html @@ -45,14 +45,7 @@
-
-
- Comments -
-
- {{ object.comments|render_markdown }} -
-
+ {% include 'inc/comments_panel.html' %}
{% endblock %} diff --git a/netbox/templates/inc/comments_panel.html b/netbox/templates/inc/comments_panel.html new file mode 100644 index 000000000..bfacb25bf --- /dev/null +++ b/netbox/templates/inc/comments_panel.html @@ -0,0 +1,14 @@ +{% load helpers %} + +
+
+ Comments +
+
+ {% if object.comments %} + {{ object.comments|render_markdown }} + {% else %} + None + {% endif %} +
+
diff --git a/netbox/templates/tenancy/tenant.html b/netbox/templates/tenancy/tenant.html index 7d251739b..dee7f7ce7 100644 --- a/netbox/templates/tenancy/tenant.html +++ b/netbox/templates/tenancy/tenant.html @@ -37,18 +37,7 @@ {% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='tenancy:tenant_list' %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_left_page object %}
diff --git a/netbox/templates/virtualization/cluster.html b/netbox/templates/virtualization/cluster.html index 402ec71bc..769ae431f 100644 --- a/netbox/templates/virtualization/cluster.html +++ b/netbox/templates/virtualization/cluster.html @@ -56,18 +56,7 @@
-
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_left_page object %}
diff --git a/netbox/templates/virtualization/virtualmachine.html b/netbox/templates/virtualization/virtualmachine.html index 339a82e65..6ea4e8d7c 100644 --- a/netbox/templates/virtualization/virtualmachine.html +++ b/netbox/templates/virtualization/virtualmachine.html @@ -91,18 +91,7 @@
{% include 'inc/custom_fields_panel.html' %} {% include 'extras/inc/tags_panel.html' with tags=object.tags.all url='virtualization:virtualmachine_list' %} -
-
- Comments -
-
- {% if object.comments %} - {{ object.comments|render_markdown }} - {% else %} - None - {% endif %} -
-
+ {% include 'inc/comments_panel.html' %} {% plugin_left_page object %}