Commit 7e1f1ebc authored by Julia Radzhabova's avatar Julia Radzhabova

[DE] Check build versions for editor and revisions in versions history.

parent f9613e3a
......@@ -421,8 +421,9 @@ define([
var changes = version.changes, change, i;
if (changes && changes.length>0) {
arrVersions[arrVersions.length-1].set('changeid', changes.length-1);
arrVersions[arrVersions.length-1].set('docIdPrev', docIdPrev);
if (version.buildVersion && version.buildVersion == this.appOptions.buildVersion) {
arrVersions[arrVersions.length-1].set('changeid', changes.length-1);
arrVersions[arrVersions.length-1].set('hasChanges', changes.length>1);
for (i=changes.length-2; i>=0; i--) {
change = changes[i];
......@@ -455,6 +456,7 @@ define([
}));
arrColors.push(user.get('colorval'));
}
}
} else if (ver==0 && versions.length==1) {
arrVersions[arrVersions.length-1].set('docId', version.key + '1');
}
......@@ -972,6 +974,7 @@ define([
this.appOptions.canEditStyles = this.appOptions.canLicense && this.appOptions.canEdit;
this.appOptions.canPrint = (this.permissions.print !== false);
this.appOptions.canRename = !!this.permissions.rename;
this.appOptions.buildVersion = params.asc_getBuildVersion();
var type = /^(?:(pdf|djvu|xps))$/.exec(this.document.fileType);
this.appOptions.canDownloadOrigin = !this.appOptions.nativeApp && this.permissions.download !== false && (type && typeof type[1] === 'string');
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment