projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f27e16d
)
Fix #6910 - add extra column to shipping history report
author
Alan Knowles
<alan@roojs.com>
Tue, 3 Aug 2021 03:47:36 +0000
(11:47 +0800)
committer
Alan Knowles
<alan@roojs.com>
Tue, 3 Aug 2021 03:47:36 +0000
(11:47 +0800)
GnumericToExcel.php
patch
|
blob
|
history
diff --git
a/GnumericToExcel.php
b/GnumericToExcel.php
index
a14633e
..
5ce821d
100644
(file)
--- a/
GnumericToExcel.php
+++ b/
GnumericToExcel.php
@@
-66,7
+66,7
@@
class Pman_Core_GnumericToExcel extends Pman
exit;
}
exit;
}
- $ext = '
.
xls';
+ $ext = 'xls';
$outfmt = 'Gnumeric_Excel:excel_biff8';
$mime = 'application/vnd.ms-excel';
$outfmt = 'Gnumeric_Excel:excel_biff8';
$mime = 'application/vnd.ms-excel';
@@
-98,7
+98,7
@@
class Pman_Core_GnumericToExcel extends Pman
" --export-type={$outfmt} " .
$srcTmp . ' ' . $targetTmp . ' 2>&1';
// echo $cmd;
" --export-type={$outfmt} " .
$srcTmp . ' ' . $targetTmp . ' 2>&1';
// echo $cmd;
- //passthru($cmd);exit;
+ //passthru($cmd);exit;
//exit;
$out = `$cmd`;
clearstatcache();
//exit;
$out = `$cmd`;
clearstatcache();
@@
-111,8
+111,11
@@
class Pman_Core_GnumericToExcel extends Pman
if (!empty($_POST['format']) && $_POST['format']=='xlsx') {
require_once 'File/Convert.php';
$cc = new File_Convert($targetTmp,'application/vnd.ms-excel');
if (!empty($_POST['format']) && $_POST['format']=='xlsx') {
require_once 'File/Convert.php';
$cc = new File_Convert($targetTmp,'application/vnd.ms-excel');
-
$targetTmp = $cc->convert('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');
$targetTmp = $cc->convert('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');
+ if (empty($targetTmp)) {
+ $this->jerr("convert to xlsx failed");
+ }
+
$mime = 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet';
$ext = "xlsx";
}
$mime = 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet';
$ext = "xlsx";
}