From b183bf463c20a200a4738449f349d97e2a7b8e27 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 13 Feb 2019 10:26:54 -0500 Subject: [PATCH] Closes #2851: Include circuit provider in pass-through port connection details --- netbox/templates/dcim/inc/frontport.html | 14 +++++++++++++- netbox/templates/dcim/inc/rearport.html | 14 +++++++++++++- 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/netbox/templates/dcim/inc/frontport.html b/netbox/templates/dcim/inc/frontport.html index 3ac87e090..467101be1 100644 --- a/netbox/templates/dcim/inc/frontport.html +++ b/netbox/templates/dcim/inc/frontport.html @@ -29,7 +29,19 @@ {{ frontport.cable }} {% with far_end=frontport.get_cable_peer %} - {{ far_end.parent }} + + {% if far_end.parent.provider %} + + + {{ far_end.parent.provider }} + {{ far_end.parent }} + + {% else %} + + {{ far_end.parent }} + + {% endif %} + {{ far_end }} {% endwith %} {% else %} diff --git a/netbox/templates/dcim/inc/rearport.html b/netbox/templates/dcim/inc/rearport.html index fc6b5c1df..f994f09b2 100644 --- a/netbox/templates/dcim/inc/rearport.html +++ b/netbox/templates/dcim/inc/rearport.html @@ -28,7 +28,19 @@ {{ rearport.cable }} {% with far_end=rearport.get_cable_peer %} - {{ far_end.parent }} + + {% if far_end.parent.provider %} + + + {{ far_end.parent.provider }} + {{ far_end.parent }} + + {% else %} + + {{ far_end.parent }} + + {% endif %} + {{ far_end }} {% endwith %} {% else %}