From 84c608d9ad45af573d7b9725a957c914aeace0be Mon Sep 17 00:00:00 2001 From: mdtrooper Date: Mon, 7 Dec 2009 08:09:25 +0000 Subject: [PATCH] 2009-12-07 Miguel de Dios * operation/agentes/datos_agente.php: add a select box for select chunck to time to show data of agent module. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@2165 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 5 ++++ .../operation/agentes/datos_agente.php | 26 ++++++++----------- 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 5083459bf9..4819241fa6 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,8 @@ +2009-12-07 Miguel de Dios + + * operation/agentes/datos_agente.php: add a select box for select chunck to + time to show data of agent module. + 2009-12-05 Sancho Lerena * operation/agentes/estado_monitores.php: Names and description diff --git a/pandora_console/operation/agentes/datos_agente.php b/pandora_console/operation/agentes/datos_agente.php index 934df46318..5fd11ec306 100644 --- a/pandora_console/operation/agentes/datos_agente.php +++ b/pandora_console/operation/agentes/datos_agente.php @@ -21,7 +21,7 @@ require_once ("include/config.php"); check_login(); $module_id = get_parameter_get ("id", 0); -$period = get_parameter_get ("period", 86400); +$period = get_parameter ("period", 86400); $group = get_agentmodule_group ($module_id); if (! give_acl ($config['id_user'], $group, "AR") || $module_id == 0) { @@ -67,21 +67,17 @@ if ($result === false) { } echo "

".__('Received data from')." ".get_agentmodule_agent_name ($module_id)." / ".get_agentmodule_name ($module_id)."

"; -echo "

".human_time_description ($period) ."

"; +echo "

" . __("From the last") . " " . human_time_description ($period) ."

"; -//WIP -//echo "
"; -//$intervals = array (); -//$intervals[30] = human_time_description_raw (30); -//$intervals[60] = human_time_description_raw (60); -//$intervals[300] = human_time_description_raw (300); -//$intervals[600] = human_time_description_raw (600); -//$intervals[1200] = human_time_description_raw (1200); -//$intervals[1800] = human_time_description_raw (1800); -//$intervals[3600] = human_time_description_raw (3600); -//$intervals[7200] = human_time_description_raw (7200); -//echo print_extended_select_for_time ($intervals, 'intervalo', $period, '', '', '0', 10) . __(" seconds."); -//echo "

"; +echo "
"; +echo __("Choose a time from now") . ": "; +$intervals = array (); +$intervals[3600] = human_time_description_raw (3600); // 1 hour +$intervals[86400] = human_time_description_raw (86400); // 1 day +$intervals[604800] = human_time_description_raw (604800); // 1 week +$intervals[2592000] = human_time_description_raw (2592000); // 1 month +echo print_extended_select_for_time ($intervals, 'period', $period, 'this.form.submit();', '', '0', 10) . __(" seconds."); +echo "

"; if ($result === false) { echo '

'.__('There was a problem locating the source of the graph').'

';