mirror of
https://github.com/dbgate/dbgate
synced 2024-11-07 20:26:23 +00:00
fixed export from Mongo into Excel and CSV #240
This commit is contained in:
parent
2a1e9a6ddd
commit
b0e0cf1829
@ -30,6 +30,7 @@ async function writer({ fileName, encoding = 'utf-8', header = true, delimiter,
|
||||
csvPrepare.pipe(csvStream);
|
||||
csvStream.pipe(fileStream);
|
||||
csvPrepare['finisher'] = fileStream;
|
||||
csvPrepare.requireFixedStructure = true;
|
||||
return csvPrepare;
|
||||
}
|
||||
|
||||
|
@ -24,6 +24,7 @@ class ExcelSheetWriterStream extends stream.Writable {
|
||||
this.structure = null;
|
||||
this.fileName = fileName;
|
||||
this.sheetName = sheetName;
|
||||
this.requireFixedStructure = true;
|
||||
}
|
||||
_write(chunk, enc, next) {
|
||||
if (this.structure) {
|
||||
|
Loading…
Reference in New Issue
Block a user