From 5b06353a9da2f8b4154ce84babecca8d022446da Mon Sep 17 00:00:00 2001 From: Alfredo Cardigliano Date: Mon, 25 Aug 2025 14:46:45 +0200 Subject: [PATCH] Add table configuration for AS alerts explorer --- httpdocs/tables_config/alert_as.json | 74 ++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 httpdocs/tables_config/alert_as.json diff --git a/httpdocs/tables_config/alert_as.json b/httpdocs/tables_config/alert_as.json new file mode 100644 index 0000000000..b663b61438 --- /dev/null +++ b/httpdocs/tables_config/alert_as.json @@ -0,0 +1,74 @@ +{ + "id": "alert_as", + "data_url": "lua/rest/v2/get/as/alert/list.lua", + "use_current_page": false, + "enable_search": false, + "paging": true, + "rsp_records_field": "records", + "rsp_query_info_field": "stats", + "display_empty_rows": true, + "columns": [ + { + "id": "actions", + "title_i18n": "actions", + "sortable": false, + "sticky": true, + "min-width" : "80px", + "class": ["text-nowrap", "text-center"], + "render_v_node_type": "button_list", + "button_def_array": [ + { "id": "info", "icon": "fas fa fa-search-plus", "title_i18n": "info", "event_id": "click_button_info" }, + { "id": "acknowledge", "icon": "fas fa fa-user-check", "title_i18n": "acknowledge", "event_id": "click_button_acknowledge" }, + { "id": "disable", "icon": "fas fa fa-bell-slash", "title_i18n": "disable", "event_id": "click_button_disable" }, + { "id": "settings", "icon": "fas fa fa-cog", "title_i18n": "settings", "event_id": "click_button_settings" }, + { "id": "remove", "icon": "fas fa fa-trash", "title_i18n": "remove", "event_id": "click_button_remove" } + ] + }, + { + "title_i18n": "show_alerts.alert_datetime", + "data_field": "tstamp", + "min-width" : "115px", + "sortable": true, + "render_type": "formatValueLabelEngaged", + "class": ["text-center", "text-nowrap"] + }, + { + "title_i18n": "score", + "data_field": "score", + "sortable": true, + "min-width" : "80px", + "render_type": "formatValueLabel", + "class": ["text-center"] + }, + { + "title_i18n": "duration", + "data_field": "duration", + "sortable": true, + "min-width" : "95px", + "render_type": "secondsToTime", + "class": ["text-center", "text-nowrap"] + }, + { + "title_i18n": "alerts_dashboard.alert", + "data_field": "msg", + "sortable": false, + "min-width" : "155px", + "render_type": "formatNameDescription", + "class": ["text-nowrap"] + }, + { + "title_i18n": "as", + "data_field": "name", + "sortable": true, + "min-width" : "155px", + "render_type": "formatAS", + "class": ["text-nowrap"] + }, + { + "title_i18n": "description", + "data_field": "description", + "sortable": false, + "class": ["text-nowrap"] + } + ] +}