mirror of
https://github.com/ONLYOFFICE/server.git
synced 2026-04-07 14:04:35 +08:00
[feature] Set fileFrom to assemble in browser docx
This commit is contained in:
committed by
Sergey Konovalov
parent
a2083bce92
commit
b1b484cef2
@ -404,6 +404,16 @@ function* processDownloadFromStorage(dataConvert, cmd, task, tempDirs, authorPro
|
||||
if (task.getFromChanges()) {
|
||||
res = yield* processChanges(tempDirs, cmd, authorProps);
|
||||
}
|
||||
//todo rework
|
||||
if (!fs.existsSync(dataConvert.fileFrom)) {
|
||||
if (fs.existsSync(path.join(tempDirs.source, 'origin.docx'))) {
|
||||
dataConvert.fileFrom = path.join(tempDirs.source, 'origin.docx');
|
||||
} else if (fs.existsSync(path.join(tempDirs.source, 'origin.xlsx'))) {
|
||||
dataConvert.fileFrom = path.join(tempDirs.source, 'origin.xlsx');
|
||||
} else if (fs.existsSync(path.join(tempDirs.source, 'origin.pptx'))) {
|
||||
dataConvert.fileFrom = path.join(tempDirs.source, 'origin.pptx');
|
||||
}
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user