mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-30 01:05:39 +02:00
Merge branch 'ent-5102-Recursividad-no-funciona-en-Group-event-report' into 'develop'
fixed recursion in Group event report See merge request artica/pandorafms!2969
This commit is contained in:
commit
efe1e78489
@ -760,7 +760,7 @@ function reporting_make_reporting_data(
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
$report['contents'][] = $report_control;
|
$report['contents'][] = $report_control;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'top_n':
|
case 'top_n':
|
||||||
@ -1775,6 +1775,27 @@ function reporting_event_report_group(
|
|||||||
$event_graph_by_criticity = $event_filter['event_graph_by_criticity'];
|
$event_graph_by_criticity = $event_filter['event_graph_by_criticity'];
|
||||||
$event_graph_validated_vs_unvalidated = $event_filter['event_graph_validated_vs_unvalidated'];
|
$event_graph_validated_vs_unvalidated = $event_filter['event_graph_validated_vs_unvalidated'];
|
||||||
|
|
||||||
|
if (isset($content['recursion']) && $content['recursion'] == 1 && $content['id_group'] != 0) {
|
||||||
|
$propagate = db_get_value(
|
||||||
|
'propagate',
|
||||||
|
'tgrupo',
|
||||||
|
'id_grupo',
|
||||||
|
$content['id_group']
|
||||||
|
);
|
||||||
|
|
||||||
|
if ($propagate) {
|
||||||
|
$children = groups_get_children($content['id_group']);
|
||||||
|
$_groups = [ $content['id_group'] ];
|
||||||
|
if (!empty($children)) {
|
||||||
|
foreach ($children as $child) {
|
||||||
|
$_groups[] = (int) $child['id_grupo'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$content['id_group'] = $_groups;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$data = events_get_agent(
|
$data = events_get_agent(
|
||||||
false,
|
false,
|
||||||
$content['period'],
|
$content['period'],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user