Forced recursion while selecting All group - group_alert_report

This commit is contained in:
fbsanchez 2020-10-20 18:25:04 +02:00
parent fbccb4ac6b
commit 4babcbe647
2 changed files with 15 additions and 1 deletions

View File

@ -3744,6 +3744,19 @@ $(document).ready (function () {
$("#combo_group").change (
function () {
// Alert report group must show all matches when selecting All group
// ignoring 'recursion' option. #6497.
if ($('#type').val() == 'alert_report_group'
&& $("#combo_group").val() == 0
) {
$('#checkbox-recursion').attr('disabled',true)
$('#checkbox-recursion').attr('checked','checked')
} else {
$('#checkbox-recursion').removeAttr('checked')
$('#checkbox-recursion').removeAttr('disabled')
}
$("#id_agents").html('');
$("#id_agents2").html('');
$("#module").html('');
@ -3772,6 +3785,7 @@ $(document).ready (function () {
);
}
);
$("#combo_group").change();
$("#checkbox-recursion").change (
function () {

View File

@ -3912,7 +3912,7 @@ function reporting_alert_report_group($report, $content)
$agent_modules = alerts_get_agent_modules(
$content['id_group'],
$content['recursion']
(((string) $content['id_group'] === '0') ? true : $content['recursion'])
);
if (empty($alerts)) {