From 7d18c1fdeb818f34d83851f5c8437fcb9d2746ef Mon Sep 17 00:00:00 2001 From: mdtrooper Date: Thu, 25 Sep 2014 19:37:02 +0200 Subject: [PATCH] Fixed the groups_get_status --- pandora_console/include/functions_groups.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pandora_console/include/functions_groups.php b/pandora_console/include/functions_groups.php index 20a28f490d..75a92be91d 100644 --- a/pandora_console/include/functions_groups.php +++ b/pandora_console/include/functions_groups.php @@ -15,7 +15,6 @@ // GNU General Public License for more details. require_once ($config['homedir'].'/include/functions_users.php'); -require_once ($config['homedir'].'/include/functions_reporting.php'); /** * Check if the group is in use in the Pandora DB. @@ -532,6 +531,10 @@ function groups_get_groups_tree_recursive($groups, $trash = 0, $trash2 = 0) { * @return int Status of the agents. */ function groups_get_status ($id_group = 0) { + global $config; + + require_once ($config['homedir'].'/include/functions_reporting.php'); + $data = reporting_get_group_stats($id_group); if ($data['monitor_alerts_fired'] > 0) {