2009-10-05 Sancho Lerena <slerena@artica.es>
* include/fgraph.php: Solved ticks in X label for boolean graphs. * operation/agentes/datos_agente.php: Show absolute timestamp and data with format_numeric() filter. * operation/agentes/estado_monitores.php: Solved typo. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1999 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
26bfe1adfe
commit
0b9f395ec3
|
@ -1,3 +1,13 @@
|
||||||
|
2009-10-05 Sancho Lerena <slerena@artica.es>
|
||||||
|
|
||||||
|
* include/fgraph.php: Solved ticks in X label for boolean graphs.
|
||||||
|
|
||||||
|
* operation/agentes/datos_agente.php: Show absolute timestamp and
|
||||||
|
data with format_numeric() filter.
|
||||||
|
|
||||||
|
* operation/agentes/estado_monitores.php: Solved typo.
|
||||||
|
|
||||||
|
|
||||||
2009-10-01 Miguel de Dios <miguel.dedios@artica.es>
|
2009-10-01 Miguel de Dios <miguel.dedios@artica.es>
|
||||||
|
|
||||||
* pandora_console/godmode/reporting/reporting_builder.php: change the
|
* pandora_console/godmode/reporting/reporting_builder.php: change the
|
||||||
|
|
|
@ -1399,12 +1399,8 @@ function grafico_modulo_boolean ($id_agente_modulo, $period, $show_event,
|
||||||
$engine->fontpath = $config['fontpath'];
|
$engine->fontpath = $config['fontpath'];
|
||||||
$engine->alert_top = $show_alert ? $alert_high : false;
|
$engine->alert_top = $show_alert ? $alert_high : false;
|
||||||
$engine->alert_bottom = $show_alert ? $alert_low : false;;
|
$engine->alert_bottom = $show_alert ? $alert_low : false;;
|
||||||
|
|
||||||
if ($period < 10000)
|
$engine->xaxis_interval = $resolution/10; // Fixed to 10 ticks
|
||||||
$engine->xaxis_interval = 20;
|
|
||||||
else
|
|
||||||
$engine->xaxis_interval = $resolution * 4;
|
|
||||||
$engine->yaxis_interval = 1;
|
|
||||||
$engine->xaxis_format = 'date';
|
$engine->xaxis_format = 'date';
|
||||||
|
|
||||||
$engine->single_graph ();
|
$engine->single_graph ();
|
||||||
|
@ -1577,10 +1573,11 @@ if ($graphic_type) {
|
||||||
switch ($graphic_type) {
|
switch ($graphic_type) {
|
||||||
case 'sparse':
|
case 'sparse':
|
||||||
grafico_modulo_sparse ($id, $period, $draw_events, $width, $height,
|
grafico_modulo_sparse ($id, $period, $draw_events, $width, $height,
|
||||||
$label, $unit_name, $draw_alerts, $avg_only, $pure, $date);
|
$label, $unit_name, $draw_alerts, $avg_only, $pure, $date);
|
||||||
break;
|
break;
|
||||||
case "boolean":
|
case "boolean":
|
||||||
grafico_modulo_boolean ($id, $period, $draw_events, $width, $height , $label, $unit_name, $draw_alerts, 1, $pure, $date);
|
grafico_modulo_boolean ($id, $period, $draw_events, $width, $height ,
|
||||||
|
$label, $unit_name, $draw_alerts, 1, $pure, $date);
|
||||||
|
|
||||||
break;
|
break;
|
||||||
case "estado_incidente":
|
case "estado_incidente":
|
||||||
|
|
|
@ -85,9 +85,14 @@ foreach ($result as $row) {
|
||||||
} else {
|
} else {
|
||||||
$data[0] = '';
|
$data[0] = '';
|
||||||
}
|
}
|
||||||
$data[1] = print_timestamp ($row["utimestamp"], true);
|
|
||||||
|
// This returns data with absolute user-defined timestamp format
|
||||||
|
// and numeric by data managed with 2 decimals, and not using Graph format
|
||||||
|
// (replacing 1000 by K and 1000000 by G, like version 2.x
|
||||||
|
|
||||||
|
$data[1] = date ($config["date_format"], $row["utimestamp"]);
|
||||||
if (is_numeric ($row["datos"])) {
|
if (is_numeric ($row["datos"])) {
|
||||||
$data[2] = $row["datos"];
|
$data[2] = format_numeric($row["datos"],2);
|
||||||
} else {
|
} else {
|
||||||
$data[2] = safe_input ($row["datos"]);
|
$data[2] = safe_input ($row["datos"]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -126,7 +126,7 @@ foreach ($modules as $module) {
|
||||||
$salida = "<span title='".$module['datos']."' style='white-space: nowrap;'>".substr(salida_limpia($module["datos"]),0,12)."</span>";
|
$salida = "<span title='".$module['datos']."' style='white-space: nowrap;'>".substr(salida_limpia($module["datos"]),0,12)."</span>";
|
||||||
}
|
}
|
||||||
|
|
||||||
$data[5] .= $salida;
|
$data[5] = $salida;
|
||||||
$graph_type = return_graphtype ($module["id_tipo_modulo"]);
|
$graph_type = return_graphtype ($module["id_tipo_modulo"]);
|
||||||
if ($module['history_data'] == 1){
|
if ($module['history_data'] == 1){
|
||||||
$nombre_tipo_modulo = get_moduletype_name ($module["id_tipo_modulo"]);
|
$nombre_tipo_modulo = get_moduletype_name ($module["id_tipo_modulo"]);
|
||||||
|
|
Loading…
Reference in New Issue