Subject: | Unable to use dates as date |
If you supply the data with dates like '2006-04-04' it treats this as a
number not as a string.
Problem is in _xml_chart_data_row, suggested fix below
sub _xml_chart_data_row {
my $self = shift;
my ($row) = @_;
my $output = '<row>';
if ($row->[0]) {
$output .= '<string>'.$row->[0].'</string>';
} else {
$output .= '<null/>';
}
foreach my $n (@$row[1..$#$row]) {
$n ||= '' unless defined $n;
if ( $n =~ m/[^0-9]/ ) {
$output .= "<string>$n</string>";
} else {
$output .= "<number>$n</number>";
}
}
$output .= '</row>';
return $output;
}
Ive tried this and it works :)