From 10fda5201d55b9e4fede7eccbca71b1ffed14d6f Mon Sep 17 00:00:00 2001 From: raulmateos Date: Tue, 8 May 2007 11:24:57 +0000 Subject: [PATCH] 2007-05-08 Raul Mateos * godmode/modules/*.php, godmode/agentes/*.php: Added icon to buttons. * godmode/grupos/configurar_grupo.php: Changed datos2 style to datos in second row. * operation/agentes/estado_monitores.php: Added code to show "Never" if timestamp is 00-00... * operation/agentes/estado_ultimopaquete.php: Added title to tag, to show name when is longer than 15 chars. * general/logon_ok.php: Closed some html tags. Reduce size of table. * include/styles/pandora.css: Changed some colours. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@454 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 17 ++++++ pandora_console/general/logon_ok.php | 58 +++++++++---------- .../godmode/agentes/agent_manager.php | 4 +- .../godmode/agentes/manage_config.php | 2 +- .../godmode/agentes/modificar_agente.php | 4 +- .../godmode/grupos/configurar_grupo.php | 4 +- .../godmode/modules/manage_nc_groups_form.php | 6 +- .../manage_network_components_form.php | 6 +- .../modules/manage_network_templates_form.php | 6 +- pandora_console/include/styles/pandora.css | 16 ++--- .../operation/agentes/estado_monitores.php | 17 +++++- .../agentes/estado_ultimopaquete.php | 4 +- 12 files changed, 88 insertions(+), 56 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 0d2599bd44..3a16af6c54 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,20 @@ +2007-05-08 Raul Mateos + + * godmode/modules/*.php, godmode/agentes/*.php: Added icon to buttons. + + * godmode/grupos/configurar_grupo.php: Changed datos2 style to datos in + second row. + + * operation/agentes/estado_monitores.php: Added code to show "Never" if + timestamp is 00-00... + + * operation/agentes/estado_ultimopaquete.php: Added title to tag, + to show name when is longer than 15 chars. + + * general/logon_ok.php: Closed some html tags. Reduce size of table. + + * include/styles/pandora.css: Changed some colours. + 2007-05-07 Raul Mateos * general/header.php: Made smaller. diff --git a/pandora_console/general/logon_ok.php b/pandora_console/general/logon_ok.php index b54a4eb168..86684733f6 100644 --- a/pandora_console/general/logon_ok.php +++ b/pandora_console/general/logon_ok.php @@ -36,7 +36,8 @@ echo '' . $lang_label["comments"] . ''; // Skip offset records - $query1="SELECT * FROM tsesion WHERE (TO_DAYS(fecha) > TO_DAYS(NOW()) - 7) AND ID_usuario = '" . $nick . "' ORDER BY fecha DESC limit 15"; + $query1="SELECT * FROM tsesion WHERE (TO_DAYS(fecha) > TO_DAYS(NOW()) - 7) + AND ID_usuario = '" . $nick . "' ORDER BY fecha DESC limit 15"; $result = mysql_query ($query1); $contador = 5; // Max items @@ -52,16 +53,12 @@ } $usuario = $row["ID_usuario"]; - echo ''; - echo '' . $usuario . ''; - echo ''; - echo $row["accion"]; - echo ''; - echo $row["fecha"]; - echo ''; - echo $row["IP_origen"]; - echo ''; - echo $row["descripcion"]; + echo ''; + echo '' . $usuario . ''; + echo '' . $row["accion"]. ''; + echo '' . $row["fecha"]. ''; + echo '' . $row["IP_origen"]. ''; + echo '' . $row["descripcion"]. ''; echo ''; $contador--; @@ -73,44 +70,47 @@ // Private messages pending to read ! - $sql='SELECT COUNT(*) FROM tmensajes WHERE id_usuario_destino="' . $nick . '" AND estado="FALSE";'; + $sql='SELECT COUNT(*) FROM tmensajes WHERE id_usuario_destino="'.$nick.'" + AND estado="FALSE";'; $resultado = mysql_query ($sql); $row = mysql_fetch_array ($resultado); if ($row["COUNT(*)"] != 0){ - - echo '
' . $lang_label["new_message_bra"]; - echo ''; - echo $row["COUNT(*)"] . ' '; - echo $lang_label["new_message_ket"] . '
'; + echo ' +
' . $lang_label["new_message_bra"] . ' + ' + .$row["COUNT(*)"] . ' ' + .$lang_label["new_message_ket"] . ' +
'; } // Site news ! echo '

' . $lang_label["site_news"] . '

'; $sql_news = "SELECT * FROM tnews ORDER by utimestamp LIMIT 3"; if ($result_news = mysql_query ($sql_news)){ - echo ''; - while ($row = mysql_fetch_array ($result_news)) { - + echo '
'; + while ($row = mysql_fetch_array ($result_news)) { echo ''; echo '
'; - echo $lang_label["at"]. " ". $row["utimestamp"] ." ".$lang_label["user"]. " ". $row["author"]." ".$lang_label["says"].": \"".$row["subject"]."\""; + echo $lang_label["at"]. " ". $row["utimestamp"] ." ". + $lang_label["user"]. " ". $row["author"]." ". + $lang_label["says"]. ": \"".$row["subject"]."\""; + echo '
'; echo clean_output_breaks($row["text"]); echo ''; - } echo "
"; } // Site stats - echo '

'. $lang_label["stat_title"].'

'; - echo ''; + echo '

'. $lang_label["stat_title"].'

'; + echo '
'; $query1 = "SELECT COUNT(id_usuario) FROM tusuario"; $result = mysql_query ($query1); $row = mysql_fetch_array ($result); echo "'; echo "'; echo "'; echo ""; echo "'; echo "
"; echo ''; echo $lang_label["there_are"] ."". $row[0] . ' ' . $lang_label["user_defined"]; - echo ''; + echo '
"; $query1 = "SELECT COUNT(id_agente) FROM tagente"; @@ -118,7 +118,7 @@ $row = mysql_fetch_array ($result); echo ''; echo $lang_label["there_are"] . "".$row[0]." ". $lang_label["agent_defined"]; - echo ''; + echo '
"; $query1 = "SELECT COUNT(id_agente_datos) FROM tagente_datos"; @@ -126,7 +126,7 @@ $row = mysql_fetch_array ($result); echo ''; echo $lang_label["there_are"] . "".$row[0] . ' ' . $lang_label["data_harvested"]; - echo ''; + echo '
"; $query1 = "SELECT COUNT(*) FROM talerta_agente_modulo"; @@ -134,7 +134,7 @@ $row = mysql_fetch_array ($result); echo ""; echo $lang_label["there_are"] . "".$row[0] .' ' . $lang_label["alert_defined"]; - echo ""; + echo "
"; echo ''; @@ -145,7 +145,7 @@ } else { echo 'No data received yet!'; } - echo ''; + echo '
"; echo ''; // class "jus" ?> \ No newline at end of file diff --git a/pandora_console/godmode/agentes/agent_manager.php b/pandora_console/godmode/agentes/agent_manager.php index 617dbdc4d5..1109e86834 100644 --- a/pandora_console/godmode/agentes/agent_manager.php +++ b/pandora_console/godmode/agentes/agent_manager.php @@ -176,11 +176,11 @@ while ($row=mysql_fetch_array($result)){ "; } else { echo " - "; } ?> diff --git a/pandora_console/godmode/agentes/manage_config.php b/pandora_console/godmode/agentes/manage_config.php index 76edb50b8a..5884c502c3 100644 --- a/pandora_console/godmode/agentes/manage_config.php +++ b/pandora_console/godmode/agentes/manage_config.php @@ -306,7 +306,7 @@ if (comprueba_login() == 0) '; ?> - '; ?> + '; ?> diff --git a/pandora_console/godmode/agentes/modificar_agente.php b/pandora_console/godmode/agentes/modificar_agente.php index 9e8270729c..8c84b30aac 100644 --- a/pandora_console/godmode/agentes/modificar_agente.php +++ b/pandora_console/godmode/agentes/modificar_agente.php @@ -125,7 +125,7 @@ $mis_grupos = list_group ($id_user); //Print combo for groups and set an array w echo ""; echo " @@ -199,7 +199,7 @@ if (mysql_num_rows($result)){ // Create agent button echo "
"; - echo ""; echo "
"; ?> diff --git a/pandora_console/godmode/grupos/configurar_grupo.php b/pandora_console/godmode/grupos/configurar_grupo.php index 6604c9bc24..9577fd8f80 100644 --- a/pandora_console/godmode/grupos/configurar_grupo.php +++ b/pandora_console/godmode/grupos/configurar_grupo.php @@ -100,9 +100,9 @@ sec2=godmode/grupos/lista_grupos"> // Parent - echo ""; + echo ""; echo $lang_label["parent"]; - echo ''; + echo ''; echo '"; @@ -78,9 +78,9 @@ echo "
"; if ($id_sg == -1) - echo ""; + echo ""; else - echo ""; + echo ""; echo ""; diff --git a/pandora_console/godmode/modules/manage_network_components_form.php b/pandora_console/godmode/modules/manage_network_components_form.php index c8fda4811d..34be08540e 100644 --- a/pandora_console/godmode/modules/manage_network_components_form.php +++ b/pandora_console/godmode/modules/manage_network_components_form.php @@ -191,7 +191,7 @@ if ($id_nc != -1) echo "
"; else echo ""; -echo ""; +echo ""; echo ""; echo ''.$lang_label["module_name"]; @@ -271,9 +271,9 @@ echo ""; echo ""; if ($id_nc != "-1") - echo ''; + echo ''; else - echo ''; + echo ''; echo "
"; echo ""; diff --git a/pandora_console/godmode/modules/manage_network_templates_form.php b/pandora_console/godmode/modules/manage_network_templates_form.php index 90bc3e82b1..2132cae6f1 100644 --- a/pandora_console/godmode/modules/manage_network_templates_form.php +++ b/pandora_console/godmode/modules/manage_network_templates_form.php @@ -173,9 +173,9 @@ echo ""; echo ''; echo '
'; if ($id_np == -1) - echo ''; + echo ''; else - echo ''; + echo ''; echo "
"; echo ""; @@ -194,7 +194,7 @@ if ($id_np != -1){ echo ""; echo ''; - echo ''; + echo ''; echo ""; echo ""; } diff --git a/pandora_console/include/styles/pandora.css b/pandora_console/include/styles/pandora.css index 97d4c3b05d..e8722ff297 100644 --- a/pandora_console/include/styles/pandora.css +++ b/pandora_console/include/styles/pandora.css @@ -217,19 +217,19 @@ input.sub { } input.next { padding-right: 21px; - background: #e5e5e5 url(../../images/go.png) no-repeat right 4px; + background: #e5e5e5 url(../../images/go.png) no-repeat right 2px; } input.upd { padding-right: 21px; - background: #e5e5e5 url(../../images/upd.png) no-repeat right 5px; + background: #e5e5e5 url(../../images/upd.png) no-repeat right 3px; } input.wand { padding-right: 21px; - background: #e5e5e5 url(../../images/wand.png) no-repeat right 4px; + background: #e5e5e5 url(../../images/wand.png) no-repeat right 3px; } input.delete { padding-right: 21px; - background: #e5e5e5 url(../../images/cross.png) no-repeat right 4px; + background: #e5e5e5 url(../../images/cross.png) no-repeat right 3px; } table, img { border: 0px; @@ -240,21 +240,23 @@ th, td.lb { } td.lb_view { color: #fff; - background-color: #7ba04a; + /*background-color: #7ba04a;*/ + background-color: #778866; } td.lb, td.lb_view { height: 16px; padding-left: 3px; font-weight: bold; } -td.datos, td.datost, td.datosb, td.datos_id , td.datosf9 { +td.datos, td.datost, td.datosb , td.datos_id, td.datosf9 { background-color: #f9f9f9; } td.datos2, td.datos2t, td.datos2b, td.datos2_id , td.datos2f9 { background-color: #efefef; } td.datos3 { - background-color: #a7b896; + /*background-color: #a7b896;*/ + background-color: #d4ddc6; } td.datos_id { color: #1a313a; diff --git a/pandora_console/operation/agentes/estado_monitores.php b/pandora_console/operation/agentes/estado_monitores.php index fe8c13a82e..2b756d51bd 100644 --- a/pandora_console/operation/agentes/estado_monitores.php +++ b/pandora_console/operation/agentes/estado_monitores.php @@ -29,7 +29,12 @@ if (comprueba_login() == 0) { if (mysql_num_rows ($result_t)) { echo "

".$lang_label["monitor_listing"]." ".$lang_label["help"]."

"; echo ""; - echo " + + + + + "; $color=0; while ($row_t=mysql_fetch_array($result_t)){ # For evey module in the status table @@ -87,7 +92,15 @@ if (comprueba_login() == 0) { if ($agent_down == 1) { // If agent down, it's shown red and bold echo ""; } - echo $row_t["timestamp"].""; + else { + echo ""; + } + if ($row_t["timestamp"]=='0000-00-00 00:00:00') { + echo $lang_label["never"]; + } else { + echo $row_t["timestamp"]; + } + echo ""; } } echo '
".$lang_label["type"]."".$lang_label["module_name"]."".$lang_label["description"]."".$lang_label["status"]."".$lang_label["interval"]."".$lang_label["last_contact"]; + echo "
".$lang_label["type"]."".$lang_label["module_name"]."".$lang_label["description"]."".$lang_label["status"]."".$lang_label["interval"]."".$lang_label["last_contact"]."
'; diff --git a/pandora_console/operation/agentes/estado_ultimopaquete.php b/pandora_console/operation/agentes/estado_ultimopaquete.php index da43bec060..e914e6a3aa 100644 --- a/pandora_console/operation/agentes/estado_ultimopaquete.php +++ b/pandora_console/operation/agentes/estado_ultimopaquete.php @@ -134,7 +134,7 @@ if (comprueba_login() == 0) { } $nombre_tipo_modulo = dame_nombre_tipo_modulo($row3["id_tipo_modulo"]); - echo ""; + echo ""; echo salida_limpia(substr($row3["nombre"],0,15)); echo ""; echo ""; @@ -147,7 +147,7 @@ if (comprueba_login() == 0) { $real_interval = $intervalo_agente; } //echo $nombre_tipo_modulo; - echo ""; + echo ""; echo salida_limpia(substr($row3["descripcion"],0,32)); if (strlen($row3["descripcion"]) > 32){ echo "...";