Modified the function "reporting_render_report_html_item"

Now the item 'custom_graph' shows an interactive graph on the html
report when the user has the configuration option 'flash_charts'
enabled.
This commit is contained in:
Alejandro Gallardo Escobar 2014-10-01 13:28:08 +02:00
parent 004a9ff7b4
commit 03689c8c6d

View File

@ -3606,7 +3606,9 @@ function reporting_render_report_html_item ($content, $table, $report, $mini = f
$sizgraph_h += count($modules) * 15; $sizgraph_h += count($modules) * 15;
$table->colspan[1][0] = 3; $table->colspan[1][0] = 3;
$data = array (); $data = array();
$only_image = (bool)$config['flash_charts'] ? false : true;
require_once ($config["homedir"] . '/include/functions_graph.php'); require_once ($config["homedir"] . '/include/functions_graph.php');
$data[0] = graphic_combined_module( $data[0] = graphic_combined_module(
@ -3621,7 +3623,7 @@ function reporting_render_report_html_item ($content, $table, $report, $mini = f
0, 0,
$graph["stacked"], $graph["stacked"],
$report["datetime"], $report["datetime"],
true, $only_image,
ui_get_full_url(false) . '/'); ui_get_full_url(false) . '/');
array_push ($table->data, $data); array_push ($table->data, $data);
@ -7588,7 +7590,7 @@ function reporting_network_interfaces_table ($content, $report, $mini, $item_tit
$ttl = $is_pdf ? 2 : 1; $ttl = $is_pdf ? 2 : 1;
$graph_width = 900; $graph_width = 900;
$graph_height = 300; $graph_height = 200;
$datetime = $report['datetime']; $datetime = $report['datetime'];
$period = $content['period']; $period = $content['period'];