fix bug 32580
This commit is contained in:
parent
1c46c17a3d
commit
c725feb667
apps
documenteditor/main/app
presentationeditor/main/app
spreadsheeteditor/main/app
|
@ -932,6 +932,7 @@ define([
|
|||
this.appOptions.canLicense = params.asc_getCanLicense ? params.asc_getCanLicense() : false;
|
||||
this.appOptions.isOffline = this.api.asc_isOffline();
|
||||
this.appOptions.isReviewOnly = (this.permissions.review === true) && (this.permissions.edit === false);
|
||||
this.appOptions.canRequestEditRights = this.editorConfig.canRequestEditRights;
|
||||
this.appOptions.canEdit = (this.permissions.edit !== false || this.permissions.review === true) && // can edit or review
|
||||
(this.editorConfig.canRequestEditRights || this.editorConfig.mode !== 'view') && // if mode=="view" -> canRequestEditRights must be defined
|
||||
(!this.appOptions.isReviewOnly || this.appOptions.canLicense); // if isReviewOnly==true -> canLicense must be true
|
||||
|
|
|
@ -217,7 +217,7 @@ define([
|
|||
// this.hkSaveAs[this.mode.canDownload?'enable':'disable']();
|
||||
|
||||
this.items[1][this.mode.isEdit?'show':'hide']();
|
||||
this.items[2][!this.mode.isEdit&&this.mode.canEdit?'show':'hide']();
|
||||
this.items[2][!this.mode.isEdit && this.mode.canEdit && this.mode.canRequestEditRights ?'show':'hide']();
|
||||
|
||||
this.items[9][(!this.mode.isOffline && !this.mode.isReviewOnly && this.document&&this.document.info &&
|
||||
(this.document.info.sharingSettings&&this.document.info.sharingSettings.length>0 ||
|
||||
|
|
|
@ -712,6 +712,7 @@ define([
|
|||
/** coauthoring end **/
|
||||
this.appOptions.isOffline = this.api.asc_isOffline();
|
||||
this.appOptions.canLicense = params.asc_getCanLicense ? params.asc_getCanLicense() : false;
|
||||
this.appOptions.canRequestEditRights = this.editorConfig.canRequestEditRights;
|
||||
this.appOptions.canEdit = this.permissions.edit !== false && // can edit
|
||||
(this.editorConfig.canRequestEditRights || this.editorConfig.mode !== 'view'); // if mode=="view" -> canRequestEditRights must be defined
|
||||
this.appOptions.isEdit = this.appOptions.canLicense && this.appOptions.canEdit && this.editorConfig.mode !== 'view';
|
||||
|
|
|
@ -215,7 +215,7 @@ define([
|
|||
// this.hkSaveAs[this.mode.canDownload?'enable':'disable']();
|
||||
|
||||
this.items[1][this.mode.isEdit?'show':'hide']();
|
||||
this.items[2][!this.mode.isEdit&&this.mode.canEdit?'show':'hide']();
|
||||
this.items[2][!this.mode.isEdit && this.mode.canEdit && this.mode.canRequestEditRights ?'show':'hide']();
|
||||
|
||||
this.items[9][(!this.mode.isOffline && this.document&&this.document.info&&(this.document.info.sharingSettings&&this.document.info.sharingSettings.length>0 ||
|
||||
this.mode.sharingSettingsUrl&&this.mode.sharingSettingsUrl.length))?'show':'hide']();
|
||||
|
|
|
@ -736,6 +736,7 @@ define([
|
|||
}
|
||||
}
|
||||
|
||||
this.appOptions.canRequestEditRights = this.editorConfig.canRequestEditRights;
|
||||
this.appOptions.canEdit = this.permissions.edit !== false && // can edit
|
||||
(this.editorConfig.canRequestEditRights || this.editorConfig.mode !== 'view'); // if mode=="view" -> canRequestEditRights must be defined
|
||||
this.appOptions.isEdit = (this.appOptions.canLicense || this.appOptions.isEditDiagram || this.appOptions.isEditMailMerge) && this.permissions.edit !== false && this.editorConfig.mode !== 'view';
|
||||
|
|
|
@ -200,7 +200,7 @@ define([
|
|||
// this.hkSaveAs[this.mode.canDownload?'enable':'disable']();
|
||||
|
||||
this.items[1][this.mode.isEdit?'show':'hide']();
|
||||
this.items[2][!this.mode.isEdit&&this.mode.canEdit?'show':'hide']();
|
||||
this.items[2][!this.mode.isEdit && this.mode.canEdit && this.mode.canRequestEditRights ?'show':'hide']();
|
||||
|
||||
this.items[9][(!this.mode.isOffline && this.document&&this.document.info&&(this.document.info.sharingSettings&&this.document.info.sharingSettings.length>0 ||
|
||||
this.mode.sharingSettingsUrl&&this.mode.sharingSettingsUrl.length))?'show':'hide']();
|
||||
|
|
Loading…
Reference in a new issue