Skip to content

Commit

Permalink
Updates to release v1.3.4
Browse files Browse the repository at this point in the history
  • Loading branch information
kartik-v committed Oct 11, 2018
1 parent 8ef8f78 commit 2227908
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
4 changes: 2 additions & 2 deletions CHANGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ Change Log: `yii2-export`
**Date:** 12-Oct-2018

- (enh #273): Enhanced PDF Writer `ExportWriterPdf`.
- (enh #272): UTF-8 encoding for HTML, CSV, TEXT formats.
- (enh #272): Better UTF-8 encoding for CSV and TEXT formats.
- (enh #271): Locale specific validation messages and code enhancements.
- (enh #270): Add iframe as default target for export form download.
- (enh #270): Add iframe as a new target option for export form download.
- (enh #248): Add direct download, supplement sheets, data validation features.
- (enh #204): Better event listening for dynamic export menu rendering.
- (enh #120): Better init of `_columnSelectorEnabled`.
Expand Down
6 changes: 2 additions & 4 deletions src/ExportMenu.php
Original file line number Diff line number Diff line change
Expand Up @@ -1127,8 +1127,7 @@ public function initPhpSpreadsheetWriter($type)
$delimiter = $this->getSetting('delimiter', "\t");
$writer->setDelimiter($delimiter);
}
$needsEncoding = $t === self::FORMAT_HTML || $t === self::FORMAT_CSV || $t === self::FORMAT_TEXT;
if ($this->encoding === self::ENCODING_UTF8 && $needsEncoding) {
if ($this->encoding === self::ENCODING_UTF8 && ($t === self::FORMAT_CSV || $t === self::FORMAT_TEXT)) {
$writer->setUseBOM(true);
}
$this->raiseEvent('onInitWriter', [$this->_objWriter, $this]);
Expand Down Expand Up @@ -1222,8 +1221,7 @@ public function setVisibleColumns()
{
$columns = [];
foreach ($this->columns as $key => $column) {
if (!empty($column->hiddenFromExport) || $column instanceof ActionColumn || ($this->_columnSelectorEnabled
&& (in_array($key, $this->noExportColumns) || !in_array($key, $this->selectedColumns)))) {
if (!empty($column->hiddenFromExport) || $column instanceof ActionColumn || in_array($key, $this->noExportColumns)) {
continue;
}
$columns[] = $column;
Expand Down

0 comments on commit 2227908

Please sign in to comment.