Minor charting fixes
This commit is contained in:
parent
a3303cd05e
commit
9be433af58
|
@ -289,6 +289,12 @@ class PHPExcel_Chart_DataSeriesValues
|
|||
);
|
||||
if ($flatten) {
|
||||
$this->_dataValues = PHPExcel_Calculation_Functions::flattenArray($newDataValues);
|
||||
foreach($this->_dataValues as &$dataValue) {
|
||||
if ((!empty($dataValue)) && ($dataValue[0] == '#')) {
|
||||
$dataValue = 0.0;
|
||||
}
|
||||
}
|
||||
unset($dataValue);
|
||||
} else {
|
||||
$cellRange = explode('!',$this->_dataSource);
|
||||
if (count($cellRange) > 1) {
|
||||
|
|
|
@ -347,6 +347,10 @@ class PHPExcel_Reader_Excel2007_Chart
|
|||
}
|
||||
}
|
||||
|
||||
if (empty($seriesVal)) {
|
||||
$seriesVal = NULL;
|
||||
}
|
||||
|
||||
return array( 'formatCode' => $formatCode,
|
||||
'pointCount' => $pointCount,
|
||||
'dataValues' => $seriesVal
|
||||
|
|
|
@ -463,13 +463,13 @@ class PHPExcel_Writer_Excel2007_Chart extends PHPExcel_Writer_Excel2007_WriterPa
|
|||
$objWriter->endElement();
|
||||
$objWriter->endElement();
|
||||
|
||||
$layout = $xAxisLabel->getLayout();
|
||||
$this->_writeLayout($layout, $objWriter);
|
||||
|
||||
$objWriter->startElement('c:overlay');
|
||||
$objWriter->writeAttribute('val', 0);
|
||||
$objWriter->endElement();
|
||||
|
||||
$layout = $xAxisLabel->getLayout();
|
||||
$this->_writeLayout($layout, $objWriter);
|
||||
|
||||
$objWriter->endElement();
|
||||
|
||||
}
|
||||
|
@ -589,15 +589,15 @@ class PHPExcel_Writer_Excel2007_Chart extends PHPExcel_Writer_Excel2007_WriterPa
|
|||
$objWriter->endElement();
|
||||
$objWriter->endElement();
|
||||
|
||||
$objWriter->startElement('c:overlay');
|
||||
$objWriter->writeAttribute('val', 0);
|
||||
$objWriter->endElement();
|
||||
|
||||
if ($groupType !== PHPExcel_Chart_DataSeries::TYPE_BUBBLECHART) {
|
||||
$layout = $yAxisLabel->getLayout();
|
||||
$this->_writeLayout($layout, $objWriter);
|
||||
}
|
||||
|
||||
$objWriter->startElement('c:overlay');
|
||||
$objWriter->writeAttribute('val', 0);
|
||||
$objWriter->endElement();
|
||||
|
||||
$objWriter->endElement();
|
||||
}
|
||||
|
||||
|
|
|
@ -652,7 +652,9 @@ class PHPExcel_Writer_Excel2007_Worksheet extends PHPExcel_Writer_Excel2007_Writ
|
|||
$objWriter->startElement('protectedRange');
|
||||
$objWriter->writeAttribute('name', 'p' . md5($protectedCell));
|
||||
$objWriter->writeAttribute('sqref', $protectedCell);
|
||||
$objWriter->writeAttribute('password', $passwordHash);
|
||||
if (!empty($passwordHash)) {
|
||||
$objWriter->writeAttribute('password', $passwordHash);
|
||||
}
|
||||
$objWriter->endElement();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue