From 4cedad83cdfda364455cdb724d3b41ee76f4a803 Mon Sep 17 00:00:00 2001 From: javilanz Date: Wed, 30 Mar 2011 15:02:56 +0000 Subject: [PATCH] 2011-03-30 Javier Lanz * include/functions_reporting.php: Fixed a small problem when displaying only the graph and not the table for the exception report. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@4147 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 4 ++++ .../include/functions_reporting.php | 24 +++++++++++-------- 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index a32d0ffe38..eb7ba8a4e2 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,7 @@ +2011-03-30 Javier Lanz + * include/functions_reporting.php: Fixed a small problem when displaying + only the graph and not the table for the exception report. + 2011-03-30 Miguel de Dios * include/functions_graph.php, include/graphs/*, include/graphs/fgraph.php: diff --git a/pandora_console/include/functions_reporting.php b/pandora_console/include/functions_reporting.php index b7828b41b9..65f29bb86e 100644 --- a/pandora_console/include/functions_reporting.php +++ b/pandora_console/include/functions_reporting.php @@ -3189,11 +3189,13 @@ function render_report_html_item ($content, $table, $report, $mini = false) { $data_pie_graph = array(); foreach ($data_exceptions as $dex) { $data_pie_graph[$agent_name[$j]] = $dex; - $data = array(); - $data[0] = printTruncateText($agent_name[$j], 30); - $data[1] = printTruncateText($module_name[$j], 30); - $data[2] = $dex; - array_push ($table1->data, $data); + if ($show_graph == 0 || $show_graph == 1) { + $data = array(); + $data[0] = printTruncateText($agent_name[$j], 30); + $data[1] = printTruncateText($module_name[$j], 30); + $data[2] = $dex; + array_push ($table1->data, $data); + } $j++; } } @@ -3202,11 +3204,13 @@ function render_report_html_item ($content, $table, $report, $mini = false) { $data_pie_graph = array(); foreach ($agent_name as $an) { $data_pie_graph[$an] = $data_exceptions[$j]; - $data = array(); - $data[0] = printTruncateText($an, 30); - $data[1] = printTruncateText($module_name[$j], 30); - $data[2] = $data_exceptions[$j]; - array_push ($table1->data, $data); + if ($show_graph == 0 || $show_graph == 1) { + $data = array(); + $data[0] = printTruncateText($an, 30); + $data[1] = printTruncateText($module_name[$j], 30); + $data[2] = $data_exceptions[$j]; + array_push ($table1->data, $data); + } $j++; } }