From dcfa024dd7fc8258dde009e47c8940dd4f67309c Mon Sep 17 00:00:00 2001 From: Johannes Helmold Date: Thu, 17 Aug 2023 17:59:33 +0200 Subject: [PATCH] Add: Added an option to ignore the pagination for alert reports. The option Pagination was added to the "Compose Content for Scan Report" dialog for alerts. The default of this option is ignore, so that all results are included in the report regardless of the number of rows specified in the filter selected in the dialog. --- src/manage_sql.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/manage_sql.c b/src/manage_sql.c index 6040bf84a..80d86329c 100644 --- a/src/manage_sql.c +++ b/src/manage_sql.c @@ -12031,6 +12031,7 @@ generate_alert_filter_get (alert_t alert, const get_data_t *base_get_data, get_data_t **alert_filter_get, filter_t *filter_return) { + char *ignore_pagination; char *filt_id; filter_t filter; @@ -12070,6 +12071,14 @@ generate_alert_filter_get (alert_t alert, const get_data_t *base_get_data, else (*alert_filter_get) = NULL; + ignore_pagination = alert_data (alert, "method", + "composer_ignore_pagination"); + if (ignore_pagination) + { + (*alert_filter_get)->ignore_pagination = atoi (ignore_pagination); + g_free (ignore_pagination); + } + /* Adjust filter for report composer. * * As a first step towards a full composer we have two fields stored