Changeset 6703

Show
Ignore:
Timestamp:
10/03/08 11:50:04 (2 months ago)
Author:
jmathis
Message:

remove bug with pie-chart service in home page.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/centreon/www/include/home/pie-svc.php

    r6646 r6703  
    2222        $oreon =& $_SESSION["oreon"]; 
    2323 
    24         require_once("DB.php"); 
    25         include_once("@CENTREON_ETC@/centreon.conf.php");        
     24        require_once "DB.php" ; 
     25        include_once "@CENTREON_ETC@/centreon.conf.php";         
    2626                 
    2727        /*  
     
    4040        $pearDB->setFetchMode(DB_FETCHMODE_ASSOC); 
    4141 
    42         include_once($centreon_path . "www/include/common/common-Func-ACL.php"); 
    43         include_once($centreon_path . "www/include/common/common-Func.php"); 
     42        include_once $centreon_path . "www/include/common/common-Func-ACL.php"; 
     43        include_once $centreon_path . "www/include/common/common-Func.php"; 
    4444 
    4545        $ndo_base_prefix = getNDOPrefix(); 
    4646         
    47         include_once($centreon_path . "www/DBNDOConnect.php"); 
     47        include_once $centreon_path . "www/DBNDOConnect.php"; 
    4848 
    4949        /* 
     
    101101                $legend[] = $statistic[$ndo["current_state"]]; 
    102102                $color[] = $oreon->optGen["color_".strtolower($statistic[$ndo["current_state"]])]; 
    103                 //$svc_stat[$ndo["current_state"]] = $ndo["count(nss.current_state)"]; 
     103                $counter += $ndo["count(nss.current_state)"]; 
    104104        } 
    105105        $DBRESULT_NDO2->free(); 
     106         
    106107        /* 
    107         $DBRESULT_NDO1 =& $pearDBndo->query($rq1); 
    108         if (PEAR::isError($DBRESULT_NDO1)) 
    109                 print "DB Error : ".$DBRESULT_NDO1->getDebugInfo()."<br />"; 
    110         $data = array(); 
    111         $color = array(); 
    112         $counter = 0; 
    113          
    114         while ($ndo =& $DBRESULT_NDO1->fetchRow()){ 
    115                 $data[] = $ndo["cnt"]; 
    116                 $legend[] = $statistic[$ndo["current_state"]]; 
    117                 $color[] = $oreon->optGen["color_".strtolower($statistic[$ndo["current_state"]])];               
    118                 $counter += $ndo["cnt"]; 
    119         } 
    120         $DBRESULT_NDO1->free(); 
     108         *  create the dataset 
     109         */ 
    121110         
    122111        foreach ($data as $key => $value) 
    123112                $data[$key] = round($value / $counter * 100, 2); 
    124         */ 
    125         /* 
    126          *  create the dataset 
    127          */ 
    128113         
    129114        include_once($centreon_path.'/www/lib/ofc-library/open-flash-chart.php' );