From b0f7757a0e2bdaea5cf979109195e427d8430664 Mon Sep 17 00:00:00 2001 From: slerena Date: Sun, 17 Jun 2007 10:48:44 +0000 Subject: [PATCH] 2007-06-17 Sancho Lerena * reporting/fgraph.php: Fixed ODOmeter problem with neg. values git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@517 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 2 ++ pandora_console/reporting/fgraph.php | 8 +++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 4cdc4aa487..96a12c6eeb 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,5 +1,7 @@ 2007-06-17 Sancho Lerena + * reporting/fgraph.php: Fixed ODOmeter problem with neg. values + * include/languages/language_en.php: Just a few words added. * pandoradb.sql: Added disable field for alerts. diff --git a/pandora_console/reporting/fgraph.php b/pandora_console/reporting/fgraph.php index 7c510d5041..11cdbfdc38 100644 --- a/pandora_console/reporting/fgraph.php +++ b/pandora_console/reporting/fgraph.php @@ -1759,6 +1759,12 @@ function odo_tactic ($value1, $value2, $value3){ $Legend->setPlotarea($Plotarea); $Legend->setAlignment(IMAGE_GRAPH_ALIGN_HORIZONTAL); + if ($value1 <0) + $value1=0; + if ($value2 <0) + $value2=0; + if ($value3 <0) + $value3=0; /***************************Arrows************************/ $Arrows = & Image_Graph::factory('dataset'); $Arrows->addPoint('Global Health', $value1, 'GLOBAL'); @@ -2000,4 +2006,4 @@ if (isset($_GET["tipo"])){ graphic_error (); } else graphic_error (); -?> \ No newline at end of file +?>