diff --git a/pandora_console/include/functions_config.php b/pandora_console/include/functions_config.php index 71c520bb20..c4419d7ef2 100644 --- a/pandora_console/include/functions_config.php +++ b/pandora_console/include/functions_config.php @@ -468,7 +468,7 @@ function config_update_config () { if (!config_update_value ('type_module_charts', (string) get_parameter('type_module_charts', 'area'))) $error_update[] = __('Default type of module charts.'); if (!config_update_value ('render_proc', (bool) get_parameter('render_proc', false))) - $error_update[] = __('Display dara of proc modules in other format'); + $error_update[] = __('Display data of proc modules in other format'); if (!config_update_value ('render_proc_ok', (string) get_parameter('render_proc_ok', __('Ok') ))) $error_update[] = __('Display text proc modules have state is ok'); if (!config_update_value ('render_proc_fail', (string) get_parameter('render_proc_fail', __('Fail') ))) diff --git a/pandora_console/include/functions_modules.php b/pandora_console/include/functions_modules.php index 40f7f8ec3e..43700b2e7f 100755 --- a/pandora_console/include/functions_modules.php +++ b/pandora_console/include/functions_modules.php @@ -1638,7 +1638,8 @@ function modules_get_agentmodule_data ($id_agent_module, $period, case 31: if ( $config["render_proc"] ) { $sql = sprintf (" - SELECT IF(datos >= 1, 'OK', 'FAIL') as data, utimestamp + SELECT IF(datos >= 1, '" . $config["render_proc_ok"] . "', '" . + $config["render_proc_fail"] . "') as data, utimestamp FROM tagente_datos WHERE id_agente_modulo = %d AND utimestamp > %d AND utimestamp <= %d diff --git a/pandora_console/operation/agentes/group_view.php b/pandora_console/operation/agentes/group_view.php index 41bb397ab4..b739bb89fe 100644 --- a/pandora_console/operation/agentes/group_view.php +++ b/pandora_console/operation/agentes/group_view.php @@ -135,6 +135,7 @@ if (!empty($result_groups)) { echo "" . __("Critical") . ""; echo "" . __("Alert fired") . ""; echo ""; + foreach ($result_groups as $data) { // Calculate entire row color @@ -150,14 +151,15 @@ if (!empty($result_groups)) { $color_class = 'group_view_warn'; $status_image = ui_print_status_image ('agent_warning_ball.png', "", true); } + elseif ($data["_monitors_ok_"] > 0) { + + $color_class = 'group_view_ok'; + $status_image = ui_print_status_image ('agent_ok_ball.png', "", true); + } elseif (($data["_monitors_unknown_"] > 0) || ($data["_agents_unknown_"] > 0)) { $color_class = 'group_view_unk'; $status_image = ui_print_status_image ('agent_no_monitors_ball.png', "", true); } - elseif ($data["_monitors_ok_"] > 0) { - $color_class = 'group_view_ok'; - $status_image = ui_print_status_image ('agent_ok_ball.png', "", true); - } else { $color_class = ''; $status_image = ui_print_status_image ('agent_no_data_ball.png', "", true);