From 33af94257175994ec7952d6f0aa4170cecc20dbb Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Thu, 28 Dec 2023 15:56:22 -0500 Subject: [PATCH] Closes #14624: Add action object column to EventRuleTable --- netbox/extras/tables/tables.py | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/netbox/extras/tables/tables.py b/netbox/extras/tables/tables.py index e02365531..8482c5e24 100644 --- a/netbox/extras/tables/tables.py +++ b/netbox/extras/tables/tables.py @@ -275,7 +275,11 @@ class EventRuleTable(NetBoxTable): linkify=True ) action_type = tables.Column( - verbose_name=_('Action Type'), + verbose_name=_('Type'), + ) + action_object = tables.Column( + linkify=True, + verbose_name=_('Object'), ) content_types = columns.ContentTypesColumn( verbose_name=_('Content Types'), @@ -305,12 +309,13 @@ class EventRuleTable(NetBoxTable): class Meta(NetBoxTable.Meta): model = EventRule fields = ( - 'pk', 'id', 'name', 'enabled', 'description', 'action_type', 'content_types', 'type_create', 'type_update', - 'type_delete', 'type_job_start', 'type_job_end', 'tags', 'created', 'last_updated', + 'pk', 'id', 'name', 'enabled', 'description', 'action_type', 'action_object', 'content_types', + 'type_create', 'type_update', 'type_delete', 'type_job_start', 'type_job_end', 'tags', 'created', + 'last_updated', ) default_columns = ( - 'pk', 'name', 'enabled', 'action_type', 'content_types', 'type_create', 'type_update', 'type_delete', - 'type_job_start', 'type_job_end', + 'pk', 'name', 'enabled', 'action_type', 'action_object', 'content_types', 'type_create', 'type_update', + 'type_delete', 'type_job_start', 'type_job_end', )