ronan-gloo/codeigniter-highcharts-library — Issue #4: Passing null values to missing points graphs
Author: antoniomax
Created: 2012-01-29 00:45:03+00:00
State: open

In case you need to pass null values to generate non linear data rows, you can't since the class simply discards empty or null values.

This is the fix for the moment: [file:application/library/highcharts.php:343]

public function push_serie_data($value = '', $serie_name = ''){

if ($serie_name AND $value)
{
$index = $this->find_serie_name($serie_name);

$value = (is_numeric($value)) ? (float)$value : $value;

$this->opts['series'][$index]['data'][] = $value;
} else {
if($value===NULL) {
$index = $this->find_serie_name($serie_name);
$value = null;
$this->opts['series'][$index]['data'][] = $value;
}
}
return $this;
}