2009-04-21 Sancho Lerena <slerena@gmail.com>
* operation/servers/view_server.php: New stats for server (threads, modules in queue) and new render view (more useful and with tips in head). * functions_db.php: Server info server[img] don't return "master" icon. This icon is now stored in server[master_img]. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1639 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
bc824acde5
commit
97cc0fc556
|
@ -1,3 +1,11 @@
|
|||
2009-04-21 Sancho Lerena <slerena@gmail.com>
|
||||
|
||||
* operation/servers/view_server.php: New stats for server (threads,
|
||||
modules in queue) and new render view (more useful and with tips in head).
|
||||
|
||||
* functions_db.php: Server info server[img] don't return "master" icon.
|
||||
This icon is now stored in server[master_img].
|
||||
|
||||
2009-04-21 Jorge Gonzalez <jorgegonz@artica.es>
|
||||
|
||||
* include/languages/pt_BR.po, include/languages/it.mo,
|
||||
|
|
|
@ -1291,6 +1291,9 @@ function show_server_type ($id) {
|
|||
case 6:
|
||||
return '<img src="images/wmi.png" title="Pandora FMS WMI server">';
|
||||
break;
|
||||
case 7:
|
||||
return '<img src="images/server_web.png" title="Pandora FMS WEB server">';
|
||||
break;
|
||||
default: return "--";
|
||||
}
|
||||
}
|
||||
|
@ -2775,10 +2778,6 @@ function get_server_info ($id_server = -1) {
|
|||
break;
|
||||
}
|
||||
|
||||
if ($server['master'] == 1) {
|
||||
$server["img"] .= print_image ("images/master.png", true, array ("title" => __('Master Server')));
|
||||
}
|
||||
|
||||
if (empty ($modules_info[$server["id_server"]])) {
|
||||
$server["modules"] = 0;
|
||||
} else {
|
||||
|
|
|
@ -43,30 +43,28 @@ if ($servers === false) {
|
|||
|
||||
$table->width = '98%';
|
||||
$table->size = array ();
|
||||
$table->size[6] = '60';
|
||||
|
||||
$table->style = array ();
|
||||
$table->style[0] = 'font-weight: bold';
|
||||
|
||||
$table->align = array ();
|
||||
$table->align[1] = 'center';
|
||||
$table->align[6] = 'center';
|
||||
|
||||
$table->head = array ();
|
||||
$table->head[0] = __('Name');
|
||||
$table->head[1] = __('Status');
|
||||
$table->head[2] = __('Load');
|
||||
$table->head[3] = __('Modules');
|
||||
$table->head[4] = __('Lag');
|
||||
$table->head[5] = __('Type');
|
||||
$table->head[6] = __('Version');
|
||||
$table->head[2] = __('Type');
|
||||
$table->head[3] = __('Load'). print_help_tip (__("Modules running on this server / Total modules of this type"), true);
|
||||
$table->head[4] = __('Modules');
|
||||
$table->head[5] = __('Lag'). print_help_tip (__("Modules delayed / Max. Delay (sec)"), true);
|
||||
$table->head[6] = __('T/Q'). print_help_tip (__("Threads / Queued modules currently"), true);
|
||||
// This will have a column of data such as "6 hours"
|
||||
$table->head[7] = __('Updated');
|
||||
$table->data = array ();
|
||||
|
||||
foreach ($servers as $server) {
|
||||
$data = array ();
|
||||
$data[0] = $server['name'];
|
||||
$data[0] = '<span title="'.$server['version'].'">'.$server['name'].'</span>';
|
||||
|
||||
if ($server['status'] == 0) {
|
||||
$data[1] = print_status_image (STATUS_SERVER_DOWN, '', true);
|
||||
|
@ -74,12 +72,16 @@ foreach ($servers as $server) {
|
|||
$data[1] = print_status_image (STATUS_SERVER_OK, '', true);
|
||||
}
|
||||
|
||||
// Type
|
||||
$data[2] = '<span style="white-space:nowrap;">'.$server["img"].'</span> ('.ucfirst($server["type"]).")";
|
||||
if ($server["master"] == 1)
|
||||
$data[2] .= print_help_tip (__("This is a master server"), true);
|
||||
|
||||
// Load
|
||||
$data[2] = print_image ("reporting/fgraph.php?tipo=progress&percent=".$server["load"]."&height=20&width=80", true, array ("title" => $server["lag_txt"]));
|
||||
$data[3] = $server["modules"] . " ".__('of')." ". $server["modules_total"];
|
||||
$data[4] = '<span style="white-space:nowrap;">'.$server["lag_txt"].'</span>';
|
||||
$data[5] = '<span style="white-space:nowrap;">'.$server["img"].'</span>';
|
||||
$data[6] = $server['version'];
|
||||
$data[3] = print_image ("reporting/fgraph.php?tipo=progress&percent=".$server["load"]."&height=20&width=60", true, array ("title" => $server["lag_txt"]));
|
||||
$data[4] = $server["modules"] . " ".__('of')." ". $server["modules_total"];
|
||||
$data[5] = '<span style="white-space:nowrap;">'.$server["lag_txt"].'</span>';
|
||||
$data[6] = $server['threads'].' : '.$server['queued_modules'];
|
||||
$data[7] = print_timestamp ($server['keepalive'], true);
|
||||
|
||||
array_push ($table->data, $data);
|
||||
|
|
Loading…
Reference in New Issue