From bfbcc6bbac6985937089c013f6dcd95a2d2c52d9 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 1 Nov 2023 15:03:33 -0400 Subject: [PATCH] Simplify template code --- netbox/netbox/tables/template_code.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/netbox/netbox/tables/template_code.py b/netbox/netbox/tables/template_code.py index 6ba76217a..39a6863c6 100644 --- a/netbox/netbox/tables/template_code.py +++ b/netbox/netbox/tables/template_code.py @@ -1,11 +1,7 @@ SEARCH_RESULT_ATTRS = """ {% for name, value in record.display_attrs.items %} - {% with url=value.get_absolute_url %} - - {% if url %}{% endif %} - {{ value }} - {% if url %}{% endif %} - - {% endwith %} + + {{ value|linkify }} + {% endfor %} """