diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index f3e91b10d0..a9f2cb4af5 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,7 @@ +2012-04-19 Vanessa Gil + + * operation/tree.php: Changes in tab os. + 2012-04-19 Vanessa Gil * godmode/setup/setup.php diff --git a/pandora_console/operation/tree.php b/pandora_console/operation/tree.php index 2588ddbf1a..bd26df47ff 100644 --- a/pandora_console/operation/tree.php +++ b/pandora_console/operation/tree.php @@ -51,25 +51,7 @@ if (is_ajax ()) require_once ("general/noaccess.php"); return; } - - // Blank space below title, DONT remove this, this - // Breaks the layout when Flash charts are enabled :-o - echo '
 
'; - - //Floating div - echo '
'; - - if ($config["agentaccess"]){ - echo ''.__('Agent access rate (24h)').'
'; - - graphic_agentaccess($id_agente, 280, 110, 86400); - } - - echo '
'; - graph_graphic_agentevents ($id_agente, 290, 15, 86400, ''); - - echo '
'; - + echo '
'; echo ''; //Agent name @@ -184,6 +166,25 @@ if (is_ajax ()) //End of table echo '
'; + + // Blank space below title, DONT remove this, this + // Breaks the layout when Flash charts are enabled :-o + echo '
 
'; + + //Floating div + echo '
'; + + if ($config["agentaccess"]){ + echo ''.__('Agent access rate (24h)').'
'; + + graphic_agentaccess($id_agente, 280, 110, 86400); + } + + echo '
'; + graph_graphic_agentevents ($id_agente, 290, 15, 86400, ''); + + echo '
'; + echo '
'; echo '
'; html_print_submit_button (__('Go to agent detail'), 'upd_button', false, 'class="sub upd"'); @@ -380,7 +381,7 @@ if (is_ajax ()) html_print_image ("operation/tree/branch.png", false, array ("style" => 'vertical-align: middle;')); echo $img; - ui_print_group_icon ($row["id_grupo"], false, "groups_small", "vertical-align: middle; width: 16px; height: 16px;", false); + echo ""; echo " "; echo str_replace('.png' ,'_ball.png', @@ -391,9 +392,9 @@ if (is_ajax ()) str_replace('img', 'img style="vertical-align: middle;"', $agent_info["alert_img"]) ); echo ""; + href='javascript: loadTable(\"agent_" . $type . "\"," . $row["id_agente"] . ", " . $less . ", \"" . $id . "\")'>"; echo " "; - + echo $row["nombre"]; echo " ("; @@ -598,6 +599,7 @@ if (is_ajax ()) echo ""; echo $data; if ($row['utimestamp'] != '') { + echo " "; ui_print_help_tip ($row["timestamp"], '', 'images/clock2.png'); } echo ""; @@ -625,7 +627,7 @@ function printTree_($type) { $select_status = get_parameter('status', -1); echo ''; - echo ''; - echo '
'; + echo '
'; $avariableGroups = users_get_groups(); //db_get_all_rows_in_table('tgrupo', 'nombre'); $avariableGroupsIds = implode(',',array_keys($avariableGroups)); if($avariableGroupsIds == ''){ @@ -917,21 +919,24 @@ function printTree_($type) { $img = html_print_image ("operation/tree/last_closed.png", true, array ("style" => 'vertical-align: middle;', "id" => "tree_image_" . $type . "_" . $id, "pos_tree" => "3")); } } - - echo "
  • - " . - $img . $iconImg . __($name) . ' ('. - ''.''.$num_ok.''.''. - ' : '.$num_critical.'' . - ' : '.$num_warning.''. - ' : '.$num_unknown.''.') '. ""; - - echo "
    "; - echo "
  • \n"; + if (($type == 'os') && ($num_ok == 0) && ($num_critical == 0) && ($num_warning == 0) && ($num_unknown == 0)) { + continue; + } else { + echo "
  • + " . + $img . $iconImg ." " . __($name) . ' ('. + ''.''.$num_ok.''.''. + ' : '.$num_critical.'' . + ' : '.$num_warning.''. + ' : '.$num_unknown.''.') '. ""; + + echo "
    "; + echo "
  • \n"; + } } echo "\n"; echo '
    '; + echo ''; echo '
    '; echo ' '; echo'
    '; @@ -1130,7 +1135,8 @@ printTree_($activeTab); ); } - function loadTable(id_agent) { + function loadTable(type, div_id, less_branchs, id_father) { + id_agent = div_id; $.ajax({ type: "POST", url: "ajax.php", @@ -1138,7 +1144,8 @@ printTree_($activeTab); id_agent, success: function(data){ $('#cont').html(data); } - }); + }); + loadSubTree(type, div_id, less_branchs, id_father); }