Skip to content
This repository has been archived by the owner on May 19, 2024. It is now read-only.

Commit

Permalink
Merge pull request #17 from aserratorta/master
Browse files Browse the repository at this point in the history
Fix issue #16
  • Loading branch information
MewesK authored Oct 9, 2016
2 parents 974bfd1 + 385df20 commit 0f2825c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions Resources/doc/twig_tags.rst
Original file line number Diff line number Diff line change
Expand Up @@ -454,6 +454,7 @@ dataValidation array
merge int|string X Merge a cell range. Allows zero-based cell index or cell coordinates like 'A3'
style array X Standard PhpExcel style array
url string X
isExplicitValue boolean X If true then render cell as an explicit value (useful to show leading zero numbers as string)
======================= ========== === === ===========

Example
Expand Down
6 changes: 5 additions & 1 deletion Wrapper/XlsCellWrapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,11 @@ public function start($index = null, $value = null, array $properties = null)
$this->sheetWrapper->getRow());

if ($value !== null) {
$this->object->setValue($value);
if (array_key_exists('isExplicitValue', $properties) && $properties['isExplicitValue'] === true) {
$this->object->setValueExplicit($value);
} else {
$this->object->setValue($value);
}
}

if ($properties !== null) {
Expand Down

0 comments on commit 0f2825c

Please sign in to comment.