From e80e38a1c9aedd3d6bbed465693b8699334ef58c Mon Sep 17 00:00:00 2001 From: zarzuelo Date: Wed, 7 Dec 2011 15:04:40 +0000 Subject: [PATCH] 2011-12-07 Sergio Martin * operation/agentes/estado_agente.php godmode/agentes/modificar_agente.php: Added tab on header in the agent list views to navigate from operation to godmode sections improving usability git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@5240 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 7 +++++++ .../godmode/agentes/modificar_agente.php | 17 ++++++++++++++- .../operation/agentes/estado_agente.php | 21 ++++++++++++++++++- 3 files changed, 43 insertions(+), 2 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 1093654b59..ceef4b7d79 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,10 @@ +2011-12-07 Sergio Martin + + * operation/agentes/estado_agente.php + godmode/agentes/modificar_agente.php: Added tab on header in the + agent list views to navigate from operation to godmode sections + improving usability + 2011-12-07 Sergio Martin * include/functions_modules.php diff --git a/pandora_console/godmode/agentes/modificar_agente.php b/pandora_console/godmode/agentes/modificar_agente.php index 19340d7614..6b6fc1a56d 100644 --- a/pandora_console/godmode/agentes/modificar_agente.php +++ b/pandora_console/godmode/agentes/modificar_agente.php @@ -65,8 +65,23 @@ if (!empty($agent_to_delete)) { } } +// Prepare the tab system to the future +$tab = 'view'; + +/* Setup tab */ +$viewtab['text'] = '' + . html_print_image ("images/zoom.png", true, array ("title" =>__('View'))) + . ''; + +if($tab == 'view') + $viewtab['active'] = true; +else + $viewtab['active'] = false; + +$onheader = array('view' => $viewtab); + // Header -ui_print_page_header (__('Agent configuration')." » ".__('Agents defined in Pandora'), "", false, "", true); +ui_print_page_header (__('Agent configuration')." » ".__('Agents defined in Pandora'), "", false, "", true, $onheader); if (isset($result)) { ui_print_result_message($result, __('Success deleted agent.'), __('Could not be deleted.')); diff --git a/pandora_console/operation/agentes/estado_agente.php b/pandora_console/operation/agentes/estado_agente.php index 7f82a13a64..2a106d4af4 100644 --- a/pandora_console/operation/agentes/estado_agente.php +++ b/pandora_console/operation/agentes/estado_agente.php @@ -122,7 +122,26 @@ $refr = get_parameter('refr', 0); $recursion = get_parameter('recursion', 0); $status = (int) get_parameter ('status', -1); -ui_print_page_header ( __("Agent detail"), "images/bricks.png", false, "agent_status"); +$onheader = array(); + +if (check_acl ($config['id_user'], 0, "AW")) { + // Prepare the tab system to the future + $tab = 'setup'; + + /* Setup tab */ + $setuptab['text'] = '' + . html_print_image ("images/setup.png", true, array ("title" =>__('Setup'))) + . ''; + + if($tab == 'setup') + $setuptab['active'] = true; + else + $setuptab['active'] = false; + + $onheader = array('setup' => $setuptab); +} + +ui_print_page_header ( __("Agent detail"), "images/bricks.png", false, "agent_status", false, $onheader); echo '
';