[DE][PE] Fix version restore
This commit is contained in:
parent
4f566b1be6
commit
9a5b2487ed
|
@ -114,7 +114,8 @@ define([
|
||||||
Common.Gateway.requestRestore(record.get('revision'));
|
Common.Gateway.requestRestore(record.get('revision'));
|
||||||
else {
|
else {
|
||||||
this.isFromSelectRevision = record.get('revision');
|
this.isFromSelectRevision = record.get('revision');
|
||||||
this.api.asc_DownloadAs(new Asc.asc_CDownloadOptions(Asc.c_oAscFileType.DOCX, true));
|
var fileType = Asc.c_oAscFileType[(record.get('fileType') || '').toUpperCase()] || Asc.c_oAscFileType.DOCX;
|
||||||
|
this.api.asc_DownloadAs(new Asc.asc_CDownloadOptions(fileType, true));
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,7 +74,8 @@ define([
|
||||||
isVisible: true,
|
isVisible: true,
|
||||||
allowSelected: true,
|
allowSelected: true,
|
||||||
selected: false,
|
selected: false,
|
||||||
serverVersion: 0
|
serverVersion: 0,
|
||||||
|
fileType: 'docx'
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
@ -622,7 +622,8 @@ define([
|
||||||
selected: (opts.data.currentVersion == version.version),
|
selected: (opts.data.currentVersion == version.version),
|
||||||
canRestore: this.appOptions.canHistoryRestore && (ver < versions.length-1),
|
canRestore: this.appOptions.canHistoryRestore && (ver < versions.length-1),
|
||||||
isExpanded: true,
|
isExpanded: true,
|
||||||
serverVersion: version.serverVersion
|
serverVersion: version.serverVersion,
|
||||||
|
fileType: 'docx'
|
||||||
}));
|
}));
|
||||||
if (opts.data.currentVersion == version.version) {
|
if (opts.data.currentVersion == version.version) {
|
||||||
currentVersion = arrVersions[arrVersions.length-1];
|
currentVersion = arrVersions[arrVersions.length-1];
|
||||||
|
@ -672,7 +673,8 @@ define([
|
||||||
canRestore: this.appOptions.canHistoryRestore && this.appOptions.canDownload,
|
canRestore: this.appOptions.canHistoryRestore && this.appOptions.canDownload,
|
||||||
isRevision: false,
|
isRevision: false,
|
||||||
isVisible: true,
|
isVisible: true,
|
||||||
serverVersion: version.serverVersion
|
serverVersion: version.serverVersion,
|
||||||
|
fileType: 'docx'
|
||||||
}));
|
}));
|
||||||
arrColors.push(user.get('colorval'));
|
arrColors.push(user.get('colorval'));
|
||||||
}
|
}
|
||||||
|
|
|
@ -2267,7 +2267,8 @@ define([
|
||||||
selected: (opts.data.currentVersion == version.version),
|
selected: (opts.data.currentVersion == version.version),
|
||||||
canRestore: this.appOptions.canHistoryRestore && (ver < versions.length-1),
|
canRestore: this.appOptions.canHistoryRestore && (ver < versions.length-1),
|
||||||
isExpanded: true,
|
isExpanded: true,
|
||||||
serverVersion: version.serverVersion
|
serverVersion: version.serverVersion,
|
||||||
|
fileType: 'pptx'
|
||||||
}));
|
}));
|
||||||
if (opts.data.currentVersion == version.version) {
|
if (opts.data.currentVersion == version.version) {
|
||||||
currentVersion = arrVersions[arrVersions.length-1];
|
currentVersion = arrVersions[arrVersions.length-1];
|
||||||
|
@ -2317,7 +2318,8 @@ define([
|
||||||
canRestore: this.appOptions.canHistoryRestore && this.appOptions.canDownload,
|
canRestore: this.appOptions.canHistoryRestore && this.appOptions.canDownload,
|
||||||
isRevision: false,
|
isRevision: false,
|
||||||
isVisible: true,
|
isVisible: true,
|
||||||
serverVersion: version.serverVersion
|
serverVersion: version.serverVersion,
|
||||||
|
fileType: 'pptx'
|
||||||
}));
|
}));
|
||||||
arrColors.push(user.get('colorval'));
|
arrColors.push(user.get('colorval'));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue