]> git.sur5r.net Git - bacula/bacula/blobdiff - gui/bacula-web/bgraph.inc.php
bacula-web: Improved stored bytes graph and modified dashboard design
[bacula/bacula] / gui / bacula-web / bgraph.inc.php
index ddb8e25d302a30ee528f32bc730dee13bc6ef446..11c88d55adb8a486ab2ad4a5d41a2cb69c3619f1 100644 (file)
@@ -98,16 +98,19 @@ class BGraph{
                // Graph title
                $this->plot->SetTitle( $this->title );
 
-               //$this->plot->SetLegend(array('Engineering', 'Manufacturing', 'Administration'));
                // Setting up legends
-               $legends = array();
-               foreach( $this->data as $key => $legend ) {
-                       $this->plot->SetLegend( implode(': ',$legend) );
+               if( $this->type != 'bars' ) {
+                       $legends = array();
+                       foreach( $this->data as $key => $legend ) {
+                               $this->plot->SetLegend( implode(': ',$legend) );
+                       }
                }
 
                # Turn off X tick labels and ticks because they don't apply here:
                $this->plot->SetXTickLabelPos('none');
                $this->plot->SetXTickPos('none');
+               $this->plot->SetPlotAreaWorld(NULL, 0, NULL, NULL);
+
 
                $this->plot->DrawGraph();
        } // end function Render()