From 0963cda9fb3dc3e6f6eb61e86c6c2adc4e2af275 Mon Sep 17 00:00:00 2001 From: mdtrooper Date: Tue, 12 Aug 2014 12:58:21 +0000 Subject: [PATCH] 2014-08-12 Miguel de Dios * include/functions_modules.php: killed some unicorns and magic numbers into the function "modules_get_status". git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@10408 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 11 +++++++++++ pandora_console/include/functions_modules.php | 6 +++--- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index e9100e60f9..b2632dcc78 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,14 @@ +2014-08-12 Miguel de Dios + + * include/functions_modules.php: killed some unicorns and magic + numbers into the function "modules_get_status". + +2014-08-12 Miguel de Dios + + * images/clippy_icon.png, images/pandorin.png, + include/help/clippy/homepage.php, general/header.php: yes there is + a octopus another time in Pandora. + 2014-08-12 Miguel de Dios * include/functions_clippy.php, diff --git a/pandora_console/include/functions_modules.php b/pandora_console/include/functions_modules.php index 34b7c45f97..eca97d4ada 100644 --- a/pandora_console/include/functions_modules.php +++ b/pandora_console/include/functions_modules.php @@ -1663,15 +1663,15 @@ function modules_get_status($id_agent_module, $db_status, $data, &$status, &$tit $status = STATUS_AGENT_DOWN; $last_status = modules_get_agentmodule_last_status($id_agent_module); switch($last_status) { - case 0: + case AGENT_STATUS_NORMAL: $title = __('UNKNOWN') . " - " . __('Last status') . " " . __('NORMAL'); break; - case 1: + case AGENT_STATUS_CRITICAL: $title = __('UNKNOWN') . " - " . __('Last status') . " " . __('CRITICAL'); break; - case 2: + case AGENT_STATUS_WARNING: $title = __('UNKNOWN') . " - " . __('Last status') . " " . __('WARNING'); break;