Sfoglia il codice sorgente

Fixes: #17072 - Make active links of phone and email in Contact Assignments table (#17233)

* Add linkify_email and apply with linkify_phone to ContactAssignmentTable

* Use EmailColumn instead of linkify_email
bctiemann 1 anno fa
parent
commit
8903e4649c
1 ha cambiato i file con 4 aggiunte e 3 eliminazioni
  1. 4 3
      netbox/tenancy/tables/contacts.py

+ 4 - 3
netbox/tenancy/tables/contacts.py

@@ -113,11 +113,12 @@ class ContactAssignmentTable(NetBoxTable):
     )
     contact_phone = tables.Column(
         accessor=Accessor('contact__phone'),
-        verbose_name=_('Contact Phone')
+        verbose_name=_('Contact Phone'),
+        linkify=linkify_phone,
     )
-    contact_email = tables.Column(
+    contact_email = tables.EmailColumn(
         accessor=Accessor('contact__email'),
-        verbose_name=_('Contact Email')
+        verbose_name=_('Contact Email'),
     )
     contact_address = tables.Column(
         accessor=Accessor('contact__address'),