diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 1a4622fff0..ac643b5aa4 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,16 @@ +2012-04-03 Dario Rodriguez + + * operation/agentes/estado_agente.php, + operation/menu.php, + godmode/agentes/agent_template.php, + godmode/agentes/module_manager_editor_common.php, + godmode/agentes/agent_conf_gis.php, + godmode/agentes/module_manager.php, + godmode/agentes/modificar_agente.php, + godmode/agentes/configurar_agente.php, + godmode/menu.php: Changed Manage agent menu to Agent detail inside + Monitoring menu. + 2012-04-03 Vanessa Gil * operation/messages/message_edit.php: Show user name diff --git a/pandora_console/godmode/agentes/agent_conf_gis.php b/pandora_console/godmode/agentes/agent_conf_gis.php index 0b5c2b178f..bd6f5a074f 100644 --- a/pandora_console/godmode/agentes/agent_conf_gis.php +++ b/pandora_console/godmode/agentes/agent_conf_gis.php @@ -64,7 +64,7 @@ $table->data[4][0] = __('Ignore new GIS data:'); $table->data[4][1] = __('Disabled').' '.html_print_radio_button_extended ("update_gis_data", 1, '', $updateGisData, false, '', 'style="margin-right: 40px;"', true); $table->data[4][1] .= __('Enabled').' '.html_print_radio_button_extended ("update_gis_data", 0, '', $updateGisData, false, '', 'style="margin-right: 40px;"', true); -$url = 'index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&tab=gis&id_agente='.$id_agente; +$url = 'index.php?sec=estado&sec2=godmode/agentes/configurar_agente&tab=gis&id_agente='.$id_agente; echo "
"; html_print_input_hidden('update_gis', 1); html_print_table($table); diff --git a/pandora_console/godmode/agentes/agent_template.php b/pandora_console/godmode/agentes/agent_template.php index 45abd8d7b9..be4d1e0462 100644 --- a/pandora_console/godmode/agentes/agent_template.php +++ b/pandora_console/godmode/agentes/agent_template.php @@ -114,7 +114,7 @@ if (isset ($_POST["template_id"])) { // ========================== echo "
"; -echo ''; +echo ''; $nps = db_get_all_fields_in_table ("tnetwork_profile", "name"); if ($nps === false) { @@ -183,9 +183,9 @@ foreach ($result as $row) { } $data[2] = mb_substr ($row["descripcion"], 0, 60); - $data[3] = '' . html_print_image("images/cross.png", true, array("border" => "0", "alt" => __('Delete'), "onclick" => "if (!confirm('".__('Are you sure?') . "')) return false;")) . '  '; + $data[3] = '' . html_print_image("images/cross.png", true, array("border" => "0", "alt" => __('Delete'), "onclick" => "if (!confirm('".__('Are you sure?') . "')) return false;")) . '  '; - $data[3] .= '  ' . html_print_image("images/config.png", true, array("border" => '0', "alt" => __('Update'))) . ''; + $data[3] .= '  ' . html_print_image("images/config.png", true, array("border" => '0', "alt" => __('Update'))) . ''; array_push ($table->data, $data); } diff --git a/pandora_console/godmode/agentes/configurar_agente.php b/pandora_console/godmode/agentes/configurar_agente.php index 8db3bc7707..6f4dcd21b5 100644 --- a/pandora_console/godmode/agentes/configurar_agente.php +++ b/pandora_console/godmode/agentes/configurar_agente.php @@ -226,7 +226,7 @@ if ($id_agente) { $viewtab['active'] = false; /* Main tab */ - $maintab['text'] = '' + $maintab['text'] = '' . html_print_image ("images/cog.png", true, array ("title" =>__('Setup'))) . ''; if($tab == 'main') @@ -236,7 +236,7 @@ if ($id_agente) { $maintab['active'] = false; /* Module tab */ - $moduletab['text'] = '' + $moduletab['text'] = '' . html_print_image ("images/brick.png", true, array ("title" =>__('Modules'))) . ''; @@ -246,7 +246,7 @@ if ($id_agente) { $moduletab['active'] = false; /* Alert tab */ - $alerttab['text'] = '' + $alerttab['text'] = '' . html_print_image ("images/bell.png", true, array ("title" =>__('Alerts'))) . ''; @@ -256,7 +256,7 @@ if ($id_agente) { $alerttab['active'] = false; /* Template tab */ - $templatetab['text'] = '' + $templatetab['text'] = '' . html_print_image ("images/network.png", true, array ("title" =>__('Module templates'))) . ''; @@ -280,7 +280,7 @@ if ($id_agente) { /* Group tab */ - $grouptab['text'] = '' + $grouptab['text'] = '' . html_print_image ("images/agents_group.png", true, array( "title" => __('Group'))) . ''; @@ -291,7 +291,7 @@ if ($id_agente) { /* GIS tab */ if ($config['activate_gis']) { - $gistab['text'] = '' + $gistab['text'] = '' . html_print_image ("images/world.png", true, array ( "title" => __('GIS data'))) . ''; @@ -339,7 +339,7 @@ if ($id_agente) { $active = false; } - $url = 'index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&tab=extension&id_agente='.$id_agente . '&id_extension=' . $id; + $url = 'index.php?sec=estado&sec2=godmode/agentes/configurar_agente&tab=extension&id_agente='.$id_agente . '&id_extension=' . $id; $extension_tab = array('text' => '' . html_print_image ($image, true, array ( "title" => $name)) . '', 'active' => $active); diff --git a/pandora_console/godmode/agentes/modificar_agente.php b/pandora_console/godmode/agentes/modificar_agente.php index aedf87da6d..239c39ccd1 100644 --- a/pandora_console/godmode/agentes/modificar_agente.php +++ b/pandora_console/godmode/agentes/modificar_agente.php @@ -98,11 +98,11 @@ if (isset($result)) { if (isset($_POST["ag_group"])) { $ag_group = get_parameter_post ("ag_group"); echo ""; + action='index.php?sec=estado&sec2=godmode/agentes/modificar_agente&ag_group_refresh=".$ag_group."'>"; } else { echo ""; + action='index.php?sec=estado&sec2=godmode/agentes/modificar_agente'>"; } echo ""; @@ -129,14 +129,14 @@ echo __('Free text for search (*)'); echo "
"; // Show group selector -echo ""; +echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; -echo '
'; +echo ''; html_print_input_hidden ('new_agent', 1); html_print_submit_button (__('Create agent'), 'crt', false, 'class="sub next"'); echo "
"; @@ -343,24 +343,24 @@ if (($config['dbtype'] == 'oracle') && ($agents !== false)) { } // Prepare pagination -ui_pagination ($total_agents, "index.php?sec=gagente&sec2=godmode/agentes/modificar_agente&group_id=$ag_group&recursion=$recursion&search=$search&sort_field=$sortField&sort=$sort", $offset); +ui_pagination ($total_agents, "index.php?sec=estado&sec2=godmode/agentes/modificar_agente&group_id=$ag_group&recursion=$recursion&search=$search&sort_field=$sortField&sort=$sort", $offset); echo "
"; if ($agents !== false) { echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; @@ -400,7 +400,7 @@ if ($agents !== false) { echo ""; } echo ''; - echo "" . ui_print_truncate_text($agent["nombre"], 60, true, true, true, '[…]', 'font-size: 7pt').""; if ($agent["disabled"]) { @@ -408,15 +408,15 @@ if ($agents !== false) { echo ""; } echo '"; } echo "
".__('Agent name') . ' ' . - '' . html_print_image("images/sort_up.png", true, array("style" => $selectNameUp)) . '' . - '' . html_print_image("images/sort_down.png", true, array("style" => $selectNameDown)) . ''; + '' . html_print_image("images/sort_up.png", true, array("style" => $selectNameUp)) . '' . + '' . html_print_image("images/sort_down.png", true, array("style" => $selectNameDown)) . ''; echo "".__('R')."".__('OS'). ' ' . - '' . html_print_image("images/sort_up.png", true, array("style" => $selectOsUp)) . '' . - '' . html_print_image("images/sort_down.png", true, array("style" => $selectOsDown)) . ''; + '' . html_print_image("images/sort_up.png", true, array("style" => $selectOsUp)) . '' . + '' . html_print_image("images/sort_down.png", true, array("style" => $selectOsDown)) . ''; echo "".__('Group'). ' ' . - '' . html_print_image("images/sort_up.png", true, array("style" => $selectGroupUp)) . '' . - '' . html_print_image("images/sort_down.png", true, array("style" => $selectGroupDown)) . ''; + '' . html_print_image("images/sort_up.png", true, array("style" => $selectGroupUp)) . '' . + '' . html_print_image("images/sort_down.png", true, array("style" => $selectGroupDown)) . ''; echo "".__('Description')."".__('Delete')."'; echo html_print_image('images/cross.png', true, array("border" => '0')) . "
"; - ui_pagination ($total_agents, "index.php?sec=gagente&sec2=godmode/agentes/modificar_agente&group_id=$ag_group&search=$search&sort_field=$sortField&sort=$sort", $offset); + ui_pagination ($total_agents, "index.php?sec=estado&sec2=godmode/agentes/modificar_agente&group_id=$ag_group&search=$search&sort_field=$sortField&sort=$sort", $offset); echo "
"; } else { @@ -469,7 +469,7 @@ else { // Create agent button echo ''; -echo '
'; +echo ''; html_print_input_hidden ('new_agent', 1); html_print_submit_button (__('Create agent'), 'crt', false, 'class="sub next"'); echo "
"; diff --git a/pandora_console/godmode/agentes/module_manager.php b/pandora_console/godmode/agentes/module_manager.php index a8e34c4c6a..f7d8f0b26d 100644 --- a/pandora_console/godmode/agentes/module_manager.php +++ b/pandora_console/godmode/agentes/module_manager.php @@ -15,7 +15,7 @@ /* You can redefine $url and unset $id_agente to reuse the form. Dirty (hope temporal) hack */ if (isset ($id_agente)) { - $url = 'index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&tab=module&id_agente='.$id_agente; + $url = 'index.php?sec=estado&sec2=godmode/agentes/configurar_agente&tab=module&id_agente='.$id_agente; } @@ -192,7 +192,7 @@ if ($multiple_delete) { // MODULE VISUALIZATION TABLE // ========================== -$url = 'index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&tab=module&id_agente=' . $id_agente; +$url = 'index.php?sec=estado&sec2=godmode/agentes/configurar_agente&tab=module&id_agente=' . $id_agente; $selectNameUp = ''; $selectNameDown = ''; $selectServerUp = ''; @@ -445,7 +445,7 @@ foreach ($modules as $module) { $data = array (); } - $data[0] = ''; + $data[0] = ''; if ($module["disabled"]) $data[0] .= '' . ui_print_truncate_text($module['nombre'], 50, false, true, true, '[…]', 'font-size: 7.2pt').''; else @@ -528,12 +528,12 @@ foreach ($modules as $module) { // Delete module $data[8] = html_print_checkbox('id_delete[]', $module['id_agente_modulo'], false, true); - $data[8] .= ' '; $data[8] .= html_print_image ('images/cross.png', true, array ('title' => __('Delete'))); $data[8] .= ' '; - $data[8] .= ' '; $data[8] .= html_print_image ('images/copy.png', true, array ('title' => __('Duplicate'))); @@ -543,7 +543,7 @@ foreach ($modules as $module) { if (isset($numericModules[$type])) { if ($numericModules[$type] === true) { - $data[8] .= ' '; + $data[8] .= ' '; $data[8] .= html_print_image ('images/chart_curve.png', true, array ('title' => __('Normalize'))); $data[8] .= ''; @@ -553,7 +553,7 @@ foreach ($modules as $module) { array_push ($table->data, $data); } -echo '
'; html_print_table ($table); echo '
'; diff --git a/pandora_console/godmode/agentes/module_manager_editor_common.php b/pandora_console/godmode/agentes/module_manager_editor_common.php index daeaa6b076..3f2f8aa08d 100644 --- a/pandora_console/godmode/agentes/module_manager_editor_common.php +++ b/pandora_console/godmode/agentes/module_manager_editor_common.php @@ -126,7 +126,7 @@ $table_simple->data[0][0] = __('Name'); $table_simple->data[0][1] = html_print_input_text ('name', io_safe_output($name), '', 45, 100, true, $disabledBecauseInPolicy); if (!empty($id_agent_module) && isset($id_agente)) { - $table_simple->data[0][1] .= ' data[0][1] .= ' '; $table_simple->data[0][1] .= html_print_image ('images/cross.png', true, array ('title' => __('Delete module'))); diff --git a/pandora_console/godmode/menu.php b/pandora_console/godmode/menu.php index 5d79e7bdb1..9b4560c90d 100644 --- a/pandora_console/godmode/menu.php +++ b/pandora_console/godmode/menu.php @@ -25,8 +25,8 @@ $menu = array (); $menu['class'] = 'godmode'; if (check_acl ($config['id_user'], 0, "AW")) { - $menu["gagente"]["text"] = __('Manage agents'); - $menu["gagente"]["sec2"] = "godmode/agentes/modificar_agente"; + $menu["gagente"]["text"] = __('Manage monitoring'); + $menu["gagente"]["sec2"] = "godmode/agentes/manage_config_remote"; $menu["gagente"]["id"] = "god-agents"; $sub = array (); diff --git a/pandora_console/operation/agentes/estado_agente.php b/pandora_console/operation/agentes/estado_agente.php index 87b3bf7854..193b3b6705 100644 --- a/pandora_console/operation/agentes/estado_agente.php +++ b/pandora_console/operation/agentes/estado_agente.php @@ -129,7 +129,7 @@ if (check_acl ($config['id_user'], 0, "AW")) { $tab = 'setup'; /* Setup tab */ - $setuptab['text'] = '' + $setuptab['text'] = '' . html_print_image ("images/setup.png", true, array ("title" =>__('Setup'))) . ''; @@ -181,7 +181,16 @@ echo '
'; html_print_submit_button (__('Search'), "srcbutton", '', array ("class" => "sub search")); -echo ' 
'; +echo ' '; + +echo ''; +echo '
'; + html_print_input_hidden ('new_agent', 1); + html_print_submit_button (__('Create agent'), 'crt', false, 'class="sub next"'); +echo "
"; +echo ''; + +echo ''; if ($search != ""){ $filter = array ("string" => '%' . $search . '%'); @@ -398,15 +407,15 @@ foreach ($agents as $agent) { $data[0] .= ''; /*if (check_acl ($config['id_user'], $agent["id_grupo"], "AW")) { - $data[0] .= ''; + $data[0] .= ''; $data[0] .= html_print_image ("images/setup.png", true, array ("border" => 0, "width" => 16)); $data[0] .= ' '; }*/ @@ -477,7 +486,7 @@ if (check_acl ($config['id_user'], 0, "LM") || check_acl ($config['id_user'], 0, || check_acl ($config['id_user'], 0, "PM") || check_acl ($config['id_user'], 0, "DM") || check_acl ($config['id_user'], 0, "UM")) { - echo '
'; + echo ''; html_print_input_hidden ('new_agent', 1); html_print_submit_button (__('Create agent'), 'crt', false, 'class="sub next"'); echo '
'; diff --git a/pandora_console/operation/menu.php b/pandora_console/operation/menu.php index ab0439a457..f4ac3c7262 100644 --- a/pandora_console/operation/menu.php +++ b/pandora_console/operation/menu.php @@ -45,6 +45,20 @@ if (check_acl ($config['id_user'], 0, "AR")) { $sub["operation/agentes/estado_agente"]["text"] = __('Agent detail'); $sub["operation/agentes/estado_agente"]["refr"] = 0; + $sub["operation/agentes/estado_agente"]["subsecs"] = array("godmode/agentes/agent_conf_gis", + "godmode/agentes/agent_disk_conf_editor", + "godmode/agentes/agent_template", + "godmode/agentes/configurar_agente", + "godmode/agentes/modificar_agente", + "godmode/agentes/module_manager", + "godmode/agentes/module_manager_editor", + "godmode/agentes/module_manager_editor_common", + "godmode/agentes/module_manager_editor_data", + "godmode/agentes/module_manager_editor_network", + "godmode/agentes/module_manager_editor_plugin", + "godmode/agentes/module_manager_editor_prediction", + "godmode/agentes/module_manager_editor_wmi", + "operation/agentes/ver_agente"); $sub["operation/agentes/alerts_status"]["text"] = __('Alert detail'); $sub["operation/agentes/alerts_status"]["refr"] = 0;