2006-12-08 Raul Mateos <raulofpandora@gmail.com>

* include/config.php: Changed build
	
	* images/info.gif: New file
	
	* include/styles/pandora.css: Created new style and modified others
	
	* operation/agentes/*.php, operation/servers/*.php, godmode/agentes/*.php,
	godmode/servers/*.php,: Close some HTML tags. Changed style for not
	found items.

git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@314 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
raulmateos 2006-12-08 16:57:43 +00:00
parent 1c8299343a
commit 69524a0364
10 changed files with 107 additions and 78 deletions

View File

@ -1,3 +1,15 @@
2006-12-08 Raul Mateos <raulofpandora@gmail.com>
* include/config.php: Changed build
* images/info.gif: New file
* include/styles/pandora.css: Created new style and modified others
* operation/agentes/*.php, operation/servers/*.php, godmode/agentes/*.php,
godmode/servers/*.php,: Close some HTML tags. Changed style for not
found items.
2006-12-07 Raul Mateos <raulofpandora@gmail.com> 2006-12-07 Raul Mateos <raulofpandora@gmail.com>
* include/config.php: Changed build * include/config.php: Changed build

View File

@ -764,7 +764,7 @@ if ( $creacion_agente != 1) {
} }
echo "<tr><td colspan='7'><div class='raya'></div></td></tr>"; echo "<tr><td colspan='7'><div class='raya'></div></td></tr>";
} else } else
echo "<font class='red'>No modules</font>"; echo "<div class='nf'>No modules</div>";
?> ?>
</table> </table>
@ -830,9 +830,9 @@ $result=mysql_query($sql1);
echo $string; echo $string;
echo "<tr><td colspan='6'><div class='raya'></div></td></tr></table>"; echo "<tr><td colspan='6'><div class='raya'></div></td></tr></table>";
} }
else echo "<font class='red'>".$lang_label["no_alerts"]."</font>"; else echo "<div class='nf'>".$lang_label["no_alerts"]."</div>";
} }
else echo "<font class='red'>".$lang_label["no_modules"]."</font>"; else echo "<div class='nf'>".$lang_label["no_modules"]."</div>";
?> ?>
<br> <br>
@ -857,7 +857,9 @@ else {
} }
} }
?> ?>
<h3><?php echo $lang_label["module_asociation_form"] ?><a href='help/<?php echo $help_code ?>/chap3.php#321' target='_help' class='help'>&nbsp;<span><?php echo $lang_label["help"] ?></span></a></h3> <h3><?php echo $lang_label["module_asociation_form"] ?>
<a href='help/<?php echo $help_code ?>/chap3.php#321' target='_help' class='help'>
&nbsp;<span><?php echo $lang_label["help"] ?></span></a></h3>
<a name="modules"> <!-- Don't Delete !! --> <a name="modules"> <!-- Don't Delete !! -->
<table width="650" cellpadding="3" cellspacing="3" class="fon"> <table width="650" cellpadding="3" cellspacing="3" class="fon">
<tr><td class='lb' rowspan='8' width='5'> <tr><td class='lb' rowspan='8' width='5'>
@ -867,7 +869,7 @@ else {
<?php <?php
if ($update_module == "1") { if ($update_module == "1") {
echo "<input type='hidden' name='tipo' value='".$modulo_id_tipo_modulo."'>"; echo "<input type='hidden' name='tipo' value='".$modulo_id_tipo_modulo."'>";
echo "<i class='red'>".$lang_label["no_change_field"]."</i>"; echo "<span class='redi'>".$lang_label["no_change_field"]."</span>";
} }
else { else {
echo '<select name="tipo" onChange="type_change()">'; echo '<select name="tipo" onChange="type_change()">';

View File

@ -59,7 +59,9 @@ if (give_acl($id_user, 0, "AW")==1) {
} }
} }
echo "<h2>".$lang_label["agent_conf"]."</h2>"; echo "<h2>".$lang_label["agent_conf"]."</h2>";
echo "<h3>".$lang_label["agent_defined2"]."<a href='help/".$help_code."/chap3.php#3' target='_help' class='help'>&nbsp;<span>".$lang_label["help"]."</span></a></h3>"; echo "<h3>".$lang_label["agent_defined2"]."
<a href='help/".$help_code."/chap3.php#3' target='_help' class='help'>
&nbsp;<span>".$lang_label["help"]."</span></a></h3>";
// Load icon index from tgrupos // Load icon index from tgrupos
$iconindex_g[]=""; $iconindex_g[]="";
@ -99,10 +101,10 @@ if (give_acl($id_user, 0, "AW")==1) {
echo "<tr><td align='right' colspan='4'>"; echo "<tr><td align='right' colspan='4'>";
echo "<form method='post' action='index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&creacion=1'>"; echo "<form method='post' action='index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&creacion=1'>";
echo "<input type='submit' class='sub' name='crt' value='".$lang_label["create_agent"]."'>"; echo "<input type='submit' class='sub' name='crt' value='".$lang_label["create_agent"]."'>";
echo "</form></td></tr></table>"; echo "</form></td></tr>";
echo "</table>"; echo "</table>";
} else { } else {
echo '<font class="red">'.$lang_label["no_agent_def"].'</font><br><br>'; echo "<div class='nf'>".$lang_label["no_agent_def"]."</div>";
echo "<form method='post' action='index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&creacion=1'>"; echo "<form method='post' action='index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&creacion=1'>";
echo "<input type='submit' class='sub' name='crt' value='".$lang_label["create_agent"]."'>"; echo "<input type='submit' class='sub' name='crt' value='".$lang_label["create_agent"]."'>";
echo "</form>"; echo "</form>";

View File

@ -69,7 +69,7 @@ if (comprueba_login() == 0) {
echo "<tr><td class='datos'>".$lang_label['description']."<td class='datos'><input type='text' name='description' value='".$description."' class='w200'><input type='hidden' name='server' value='".entrada_limpia($_GET["server"])."></input>"; echo "<tr><td class='datos'>".$lang_label['description']."<td class='datos'><input type='text' name='description' value='".$description."' class='w200'><input type='hidden' name='server' value='".entrada_limpia($_GET["server"])."></input>";
} }
else { else {
echo '<font class="red">'.$lang_label["no_server"].'</font>'; echo "<div class='nf'>".$lang_label["no_server"]."</div>";
} }
echo '<tr><td colspan="3"><div class="raya"></div></td></tr>'; echo '<tr><td colspan="3"><div class="raya"></div></td></tr>';
echo '<tr><td colspan="3" align="right">'; echo '<tr><td colspan="3" align="right">';
@ -159,7 +159,7 @@ if (comprueba_login() == 0) {
echo '<tr><td colspan="12"><div class="raya"></div></td></tr></table>'; echo '<tr><td colspan="12"><div class="raya"></div></td></tr></table>';
} }
else { else {
echo '<font class="red">'.$lang_label["no_server"].'</font>'; echo "<div class='nf'>".$lang_label["no_server"]."</div>";
} }
} }

Binary file not shown.

After

Width:  |  Height:  |  Size: 244 B

View File

@ -20,7 +20,7 @@
// This is the base config file // This is the base config file
//Pandora Version //Pandora Version
$build_version="PC061207"; //PCyymmdd $build_version="PC061208"; //PCyymmdd
$pandora_version="v1.3 Beta 1"; $pandora_version="v1.3 Beta 1";
// Database configuration // Database configuration

View File

@ -249,7 +249,7 @@ td.datos_jus, td.datos2_jus {
.f9, .f9i, .f9b, td.f9, td.f9i, td.datosf9, td.datos2f9, td.datosf9i, td.datos2f9i { .f9, .f9i, .f9b, td.f9, td.f9i, td.datosf9, td.datos2f9, td.datosf9i, td.datos2f9i {
font-size: 9px; font-size: 9px;
} }
.f9i { .f9i, .redi {
font-style: italic; font-style: italic;
} }
.f9l20 { .f9l20 {
@ -276,7 +276,7 @@ td.datos_jus, td.datos2_jus {
background: url(../../images/error.gif) no-repeat; background: url(../../images/error.gif) no-repeat;
padding: 4px 1px 6px 30px; padding: 4px 1px 6px 30px;
} }
.red , .redb, .error, div.nf { .red , .redb, .redi, .error {
color: #ff0000; color: #ff0000;
} }
.sep { .sep {
@ -410,5 +410,8 @@ div.imgr>img {
right: 1; right: 1;
} }
div.nf { div.nf {
background: url(../../images/info.gif) no-repeat;
color: #9a2f0a;
margin-left: 7px; margin-left: 7px;
padding: 2px 1px 6px 25px;
} }

View File

@ -114,61 +114,64 @@ if (comprueba_login() == 0)
$array_index++; $array_index++;
} }
} }
if ($contador_agente==0) {echo "<font class='red'>".$lang_label["no_agent_def"]."</font>";} if ($contador_agente!=0) {
$ancho = ceil(sqrt($array_index+1)); $ancho = ceil(sqrt($array_index+1));
$real_count =0; // Puedo tener una tabla con mas items en ella que los que realmente debo mostrar, real count cuenta los que voy poniendo hasta llegar a array_index que son los que hay en el array $grupo. $real_count =0;
echo "<table border=0 cellpadding=10 cellspacing=10>"; echo "<table cellpadding=10 cellspacing=10>";
for ($table=0;$table < $ancho;$table++){ for ($table=0;$table < $ancho;$table++){
echo "<tr class='bot'>"; echo "<tr class='bot'>";
for ($table_row=0;$table_row < $ancho;$table_row++){ for ($table_row=0;$table_row < $ancho;$table_row++){
if ($real_count < $array_index){ if ($real_count < $array_index){
$group_name = $grupo[$real_count]["group"]; $group_name = $grupo[$real_count]["group"];
$icono_grupo = $grupo[$real_count]["icon"]; $icono_grupo = $grupo[$real_count]["icon"];
$icono_type=""; $icono_type="";
if ($grupo[$real_count]["down"]>0) { if ($grupo[$real_count]["down"]>0) {
$icono_type="<img src='images/dot_down.gif' alt=''>"; $icono_type="<img src='images/dot_down.gif' alt=''>";
}
if ($grupo[$real_count]["bad"]>0) {
$icono_type=$icono_type."<img src='images/dot_red.gif' alt=''>";
}
if ($grupo[$real_count]["ok"]>0) {
$icono_type=$icono_type."<img src='images/dot_green.gif' alt=''>";
}
if ($grupo[$real_count]["data"]>0) {
$icono_type=$icono_type."<img src='images/dot_white.gif' alt=''>";
}
// Show yellow light if there are recent alerts fired for this group
if ($grupo[$real_count]["alerts"] > 0 ){
$icono_type=$icono_type."<img src='images/dot_yellow.gif' alt=''>";
}
// TOOLTIP.
$celda = "<td class='bot' width=100><a href='index.php?sec=estado&amp;sec2=operation/agentes/estado_agente&amp;refr=60&amp;group_id=".$grupo[$real_count]["id_grupo"]."' class='info'><img class='top' src='images/groups/".$icono_grupo."_1.gif' border='0' alt=''>&nbsp;
<span>
<table cellspacing='2' cellpadding='0' style='margin-left:20px'>
<tr><td colspan='2' width='91' class='lb'>".$lang_label["agents"].": </td></tr>
<tr><td colspan='2' class='datos' align='center'><b>".$grupo[$real_count]["agent"]."</b></td></tr></table>
<table cellspacing='2' cellpadding='0' style='margin-left:20px'>
<tr><td colspan='2' width='90' class='lb'>".ucfirst($lang_label["monitors"]).":</td></tr>
<tr><td class='datos'><img src='images/b_green.gif' align='top' alt='' border='0'> ".$lang_label["ok"].": </td><td class='datos'><font class='greenb'>".$grupo[$real_count]["ok"]."</font></td></tr>
<tr><td class='datos'><img src='images/b_down.gif' align='top' alt='' border='0'> ".$lang_label["down"].": </td><td class='datos'><font class='grey'>".$grupo[$real_count]["down"]."</font></td></tr>
<tr><td class='datos'><img src='images/b_red.gif' align='top' alt='' border='0'> ".$lang_label["fail"].": </td><td class='datos'><font class='redb'>".$grupo[$real_count]["bad"]."</font></td></tr>
<tr><td class='datos'><img src='images/b_yellow.gif' align='top' alt='' border='0'> ".$lang_label["alerts"].": </td><td class='datos'><font class='grey'>".$grupo[$real_count]["alerts"]."</font></td></tr>
</table></span></a>";
// Render network exec module button, only when this group is writtable by user
if (give_acl($id_user, $grupo[$real_count]["id_grupo"], "AW")==1){
$celda = $celda . "<a href='index.php?sec=estado&sec2=operation/agentes/estado_grupo&update_netgroup=".$grupo[$real_count]["id_grupo"]."'><img src='images/target.gif' border=0></a>";
}
$celda = $celda . "<br><br>".$icono_type."<br><br><font class='gr'>".$group_name."</font>";
echo $celda;
} }
if ($grupo[$real_count]["bad"]>0) { $real_count++;
$icono_type=$icono_type."<img src='images/dot_red.gif' alt=''>";
}
if ($grupo[$real_count]["ok"]>0) {
$icono_type=$icono_type."<img src='images/dot_green.gif' alt=''>";
}
if ($grupo[$real_count]["data"]>0) {
$icono_type=$icono_type."<img src='images/dot_white.gif' alt=''>";
}
// Show yellow light if there are recent alerts fired for this group
if ($grupo[$real_count]["alerts"] > 0 ){
$icono_type=$icono_type."<img src='images/dot_yellow.gif' alt=''>";
}
// TOOLTIP.
$celda = "<td class='bot' width=100><a href='index.php?sec=estado&amp;sec2=operation/agentes/estado_agente&amp;refr=60&amp;group_id=".$grupo[$real_count]["id_grupo"]."' class='info'><img class='top' src='images/groups/".$icono_grupo."_1.gif' border='0' alt=''>&nbsp;
<span>
<table cellspacing='2' cellpadding='0' style='margin-left:20px'>
<tr><td colspan='2' width='91' class='lb'>".$lang_label["agents"].": </td></tr>
<tr><td colspan='2' class='datos' align='center'><b>".$grupo[$real_count]["agent"]."</b></td></tr></table>
<table cellspacing='2' cellpadding='0' style='margin-left:20px'>
<tr><td colspan='2' width='90' class='lb'>".ucfirst($lang_label["monitors"]).":</td></tr>
<tr><td class='datos'><img src='images/b_green.gif' align='top' alt='' border='0'> ".$lang_label["ok"].": </td><td class='datos'><font class='greenb'>".$grupo[$real_count]["ok"]."</font></td></tr>
<tr><td class='datos'><img src='images/b_down.gif' align='top' alt='' border='0'> ".$lang_label["down"].": </td><td class='datos'><font class='grey'>".$grupo[$real_count]["down"]."</font></td></tr>
<tr><td class='datos'><img src='images/b_red.gif' align='top' alt='' border='0'> ".$lang_label["fail"].": </td><td class='datos'><font class='redb'>".$grupo[$real_count]["bad"]."</font></td></tr>
<tr><td class='datos'><img src='images/b_yellow.gif' align='top' alt='' border='0'> ".$lang_label["alerts"].": </td><td class='datos'><font class='grey'>".$grupo[$real_count]["alerts"]."</font></td></tr>
</table></span></a>";
// Render network exec module button, only when this group is writtable by user
if (give_acl($id_user, $grupo[$real_count]["id_grupo"], "AW")==1){
$celda = $celda . "<a href='index.php?sec=estado&sec2=operation/agentes/estado_grupo&update_netgroup=".$grupo[$real_count]["id_grupo"]."'><img src='images/target.gif' border=0></a>";
}
$celda = $celda . "<br><br>".$icono_type."<br><br><font class='gr'>".$group_name."</font>";
echo $celda;
} }
$real_count++; echo "</tr>";
}
echo "</table>";
} else {
echo "<div class='nf'>".$lang_label["no_agent_def"]."</div>";
} }
echo "</tr>";
}
echo "</table>";
} }
else { else {
echo '<tr><td></td></tr><tr><td class="red">'.$lang_label["no_agent"].'</td></tr></table>'; echo "<div class='nf'>".$lang_label["no_agent"]."</div>";
} }
} }
else { else {

View File

@ -65,32 +65,37 @@ if (comprueba_login() == 0) {
else else
$agent_down = 0; $agent_down = 0;
echo "<tr><td class='".$tdcolor."'>".$est_tipo; echo "<tr><td class='".$tdcolor."'>".$est_tipo."</td>";
echo "<td class='".$tdcolor."'>".$est_modulo; echo "<td class='".$tdcolor."'>".$est_modulo."</td>";
echo "<td class='".$tdcolor."f9'>".substr($est_description,0,32); echo "<td class='".$tdcolor."f9'>"
.substr($est_description,0,32)."</td>";
// echo "<td class='datos'>".$row3["datos"]; // echo "<td class='datos'>".$row3["datos"];
if ($agent_down == 1) if ($agent_down == 1)
echo "<td class='".$tdcolor."' align='center'><img src='images/b_down.gif'>"; echo "<td class='".$tdcolor."' align='center'>
<img src='images/b_down.gif'></td>";
else else
if ($est_estado == 1) if ($est_estado == 1)
if ($est_cambio ==1) if ($est_cambio ==1)
echo "<td class='".$tdcolor."' align='center'><img src='images/b_yellow.gif'>"; echo "<td class='".$tdcolor."' align='center'>
<img src='images/b_yellow.gif'></td>";
else else
echo "<td class='".$tdcolor."' align='center'><img src='images/b_red.gif'>"; echo "<td class='".$tdcolor."' align='center'>
<img src='images/b_red.gif'></td>";
else else
echo "<td class='".$tdcolor."' align='center'><img src='images/b_green.gif'>"; echo "<td class='".$tdcolor."' align='center'>
<img src='images/b_green.gif'></td>";
echo "<td class='".$tdcolor."'>"; echo "<td class='".$tdcolor."'>";
echo $temp_interval; echo $temp_interval."</td>";
echo "<td class='".$tdcolor."f9'>"; echo "<td class='".$tdcolor."f9'>";
if ($agent_down == 1) // Si el agente esta down, lo mostramos en negrita y en rojo if ($agent_down == 1) { // If agent down, it's shown red and bold
echo "<b><font color='red'>"; echo "<span class='redb'>";
}
echo $row_t["timestamp"]; echo $row_t["timestamp"]."</span></td>";
} }
} }
echo '<tr><td colspan="7"><div class="raya"></div></td></tr></table>'; echo '<tr><td colspan="7"><div class="raya"></div></td></tr></table>';
} }
else else
echo "<font class='red'>".$lang_label["no_monitors"]."</font>"; echo "<div class='nf'>".$lang_label["no_monitors"]."</div>";
} }
?> ?>

View File

@ -191,6 +191,8 @@ if (comprueba_login() == 0) {
} }
echo '<tr><td colspan="9"><div class="raya"></div></td></tr></table>'; echo '<tr><td colspan="9"><div class="raya"></div></td></tr></table>';
} }
else echo "<font class='red'>".$lang_label["no_modules"]."</font>"; else {
echo "<div class='nf'>".$lang_label["no_modules"]."</div>";
} }
}
?> ?>