*
 */
require_once '../../config.inc.php';
require_once 'charts.inc.php';
testlinkInitPage($db, false, false, "checkRights");
$cfg = new stdClass();
$cfg->scale = new stdClass();
$chart_cfg = config_get('results');
$chart_cfg = $chart_cfg['charts']['dimensions']['topLevelSuitesBarChart'];
$cfg->chartTitle = lang_get($chart_cfg['chartTitle']);
$cfg->XSize = $chart_cfg['XSize'];
$cfg->YSize = $chart_cfg['YSize'];
$cfg->beginX = $chart_cfg['beginX'];
$cfg->beginY = $chart_cfg['beginY'];
$cfg->scale->legendXAngle = $chart_cfg['legendXAngle'];
$info = getDataAndScale($db);
createChart($info, $cfg);
/*
  function: getDataAndScale
  args :
  
  returns: 
*/
function getDataAndScale(&$dbHandler)
{
    $obj = new stdClass();
    $totals = null;
    $resultsCfg = config_get('results');
    $dataSet = $_SESSION['statistics']['getTopLevelSuites'];
    $mapOfAggregate = $_SESSION['statistics']['getAggregateMap'];
    $obj->canDraw = !is_null($dataSet);
 */
require_once '../../config.inc.php';
require_once 'common.php';
require_once 'charts.inc.php';
$cfg = new stdClass();
$cfg->scale = new stdClass();
$chart_cfg = config_get('results');
$chart_cfg = $chart_cfg['charts']['dimensions']['topLevelSuitesBarChart'];
$cfg->chartTitle = lang_get($chart_cfg['chartTitle']);
$cfg->XSize = $chart_cfg['XSize'];
$cfg->YSize = $chart_cfg['YSize'];
$cfg->beginX = $chart_cfg['beginX'];
$cfg->beginY = $chart_cfg['beginY'];
$cfg->scale->legendXAngle = $chart_cfg['legendXAngle'];
$args = init_args($db);
$info = getDataAndScale($db, $args);
if (property_exists($args, 'debug')) {
    new dBug($info);
    die;
}
createChart($info, $cfg);
/*
  function: getDataAndScale
  args :
  
  returns: 
*/
function getDataAndScale(&$dbHandler, $argsObj)
{
    $obj = new stdClass();
    $totals = null;