2012-02-13 Sergio Martin <sergio.martin@artica.es>
* include/graphs/functions_pchart.php include/graphs/fgraph.php include/functions_reporting.php include/functions_visual_map.php: Fixed little graphs into the visual maps of the widgets (min height control added) git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@5570 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
8f15ef93fb
commit
bf4c0f1553
|
@ -1,3 +1,12 @@
|
||||||
|
2012-02-13 Sergio Martin <sergio.martin@artica.es>
|
||||||
|
|
||||||
|
* include/graphs/functions_pchart.php
|
||||||
|
include/graphs/fgraph.php
|
||||||
|
include/functions_reporting.php
|
||||||
|
include/functions_visual_map.php: Fixed little
|
||||||
|
graphs into the visual maps of the widgets
|
||||||
|
(min height control added)
|
||||||
|
|
||||||
2012-02-13 Miguel de Dios <miguel.dedios@artica.es>
|
2012-02-13 Miguel de Dios <miguel.dedios@artica.es>
|
||||||
|
|
||||||
* operation/agentes/estado_monitores.php, operation/agentes/ver_agente.php:
|
* operation/agentes/estado_monitores.php, operation/agentes/ver_agente.php:
|
||||||
|
|
|
@ -1869,8 +1869,9 @@ function reporting_get_group_detailed_event ($id_group, $period = 0, $date = 0,
|
||||||
$table->head = array ();
|
$table->head = array ();
|
||||||
$table->head[0] = __('Event name');
|
$table->head[0] = __('Event name');
|
||||||
$table->head[1] = __('Event type');
|
$table->head[1] = __('Event type');
|
||||||
$table->head[2] = __('Criticity');
|
$table->head[2] = __('Agent');
|
||||||
$table->head[3] = __('Timestamp');
|
$table->head[3] = __('Criticity');
|
||||||
|
$table->head[4] = __('Timestamp');
|
||||||
|
|
||||||
$events = events_get_group_events($id_group, $period, $date);
|
$events = events_get_group_events($id_group, $period, $date);
|
||||||
|
|
||||||
|
@ -1879,8 +1880,9 @@ function reporting_get_group_detailed_event ($id_group, $period = 0, $date = 0,
|
||||||
$data = array ();
|
$data = array ();
|
||||||
$data[0] = io_safe_output($event['evento']);
|
$data[0] = io_safe_output($event['evento']);
|
||||||
$data[1] = $event['event_type'];
|
$data[1] = $event['event_type'];
|
||||||
$data[2] = get_priority_name ($event['criticity']);
|
$data[2] = agents_get_name ($event['id_agente']);
|
||||||
$data[3] = $event['timestamp'];
|
$data[3] = get_priority_name ($event['criticity']);
|
||||||
|
$data[4] = $event['timestamp'];
|
||||||
array_push ($table->data, $data);
|
array_push ($table->data, $data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -947,20 +947,18 @@ function visual_map_print_visual_map ($id_layout, $show_links = true, $draw_line
|
||||||
echo '<a href="index.php?sec=visualc&sec2=operation/visual_console/render_view&pure='.$config["pure"].'&id='.$layout_data['id_layout_linked'].'">';
|
echo '<a href="index.php?sec=visualc&sec2=operation/visual_console/render_view&pure='.$config["pure"].'&id='.$layout_data['id_layout_linked'].'">';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($resizedMap) {
|
|
||||||
|
|
||||||
|
if ($resizedMap) {
|
||||||
|
$layout_data['width'] = ((integer)($proportion * $layout_data['width']));
|
||||||
|
$layout_data['height'] = ((integer)($proportion * $layout_data['height']));
|
||||||
|
}
|
||||||
|
|
||||||
// ATTENTION: DO NOT USE & here because is bad-translated and doesnt work
|
// ATTENTION: DO NOT USE & here because is bad-translated and doesnt work
|
||||||
// resulting fault image links :(
|
// resulting fault image links :(
|
||||||
|
echo grafico_modulo_sparse ($layout_data['id_agente_modulo'], $layout_data['period'],
|
||||||
echo grafico_modulo_sparse ($layout_data['id_agente_modulo'], $layout_data['period'],
|
false, $layout_data['width'], $layout_data['height'],
|
||||||
false, ((integer)($proportion * $layout_data['width'])), ((integer)($proportion * $layout_data['height'])),
|
'', null, false, 1, false, 0, '', 0, 0, true, true, '', 2);
|
||||||
'', null, false, 1, false, 0, '', 0, 0, true, true);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
echo grafico_modulo_sparse ($layout_data['id_agente_modulo'], $layout_data['period'],
|
|
||||||
false, $layout_data['width'], $layout_data['height'],
|
|
||||||
'', null, false, 1, false, 0, '', 0, 0, true, true);
|
|
||||||
}
|
|
||||||
echo "</a>";
|
echo "</a>";
|
||||||
echo "</div>";
|
echo "</div>";
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -194,6 +194,11 @@ function area_graph($flash_chart, $chart_data, $width, $height, $color, $legend,
|
||||||
$long_index, $no_data_image, $xaxisname = "", $yaxisname = "", $homeurl="",
|
$long_index, $no_data_image, $xaxisname = "", $yaxisname = "", $homeurl="",
|
||||||
$water_mark = "", $font = '', $font_size = '', $unit = '', $ttl = 1) {
|
$water_mark = "", $font = '', $font_size = '', $unit = '', $ttl = 1) {
|
||||||
|
|
||||||
|
// ATTENTION: The min height is 101
|
||||||
|
if($height <= 100) {
|
||||||
|
$height = 101;
|
||||||
|
}
|
||||||
|
|
||||||
if (empty($chart_data)) {
|
if (empty($chart_data)) {
|
||||||
return '<img src="' . $no_data_image . '" />';
|
return '<img src="' . $no_data_image . '" />';
|
||||||
}
|
}
|
||||||
|
|
|
@ -215,7 +215,7 @@ switch($graph_type) {
|
||||||
case 'pie3d':
|
case 'pie3d':
|
||||||
case 'pie2d':
|
case 'pie2d':
|
||||||
break;
|
break;
|
||||||
case 'default':
|
default:
|
||||||
if(!is_array(reset($data_values))) {
|
if(!is_array(reset($data_values))) {
|
||||||
$data_values = array($data_values);
|
$data_values = array($data_values);
|
||||||
if(is_array($colors) && !empty($colors)) {
|
if(is_array($colors) && !empty($colors)) {
|
||||||
|
|
Loading…
Reference in New Issue