Fix Bug 47637

This commit is contained in:
Julia Radzhabova 2020-11-24 14:54:41 +03:00
parent c7d8aec49e
commit 67745e22b1
6 changed files with 20 additions and 8 deletions

View file

@ -1119,7 +1119,7 @@ define([
var licType = params.asc_getLicenseType();
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS
|| (licType===Asc.c_oLicenseResult.SuccessLimit || licType===Asc.c_oLicenseResult.ExpiredLimited) && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
|| licType===Asc.c_oLicenseResult.SuccessLimit && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
this._state.licenseType = licType;
if (this._isDocReady)
@ -1199,6 +1199,8 @@ define([
});
return;
}
if (Asc.c_oLicenseResult.ExpiredLimited === licType)
this._state.licenseType = licType;
if ( this.onServerVersion(params.asc_getBuildVersion()) ) return;
@ -1245,7 +1247,7 @@ define([
this.appOptions.canProtect = (this.appOptions.isSignatureSupport || this.appOptions.isPasswordSupport);
this.appOptions.canEditContentControl = (this.permissions.modifyContentControl!==false);
this.appOptions.canHelp = !((typeof (this.editorConfig.customization) == 'object') && this.editorConfig.customization.help===false);
this.appOptions.canFillForms = ((this.permissions.fillForms===undefined) ? this.appOptions.isEdit : this.permissions.fillForms) && (this.editorConfig.mode !== 'view');
this.appOptions.canFillForms = this.appOptions.canLicense && ((this.permissions.fillForms===undefined) ? this.appOptions.isEdit : this.permissions.fillForms) && (this.editorConfig.mode !== 'view');
this.appOptions.isRestrictedEdit = !this.appOptions.isEdit && (this.appOptions.canComments || this.appOptions.canFillForms);
if (this.appOptions.isRestrictedEdit && this.appOptions.canComments && this.appOptions.canFillForms) // must be one restricted mode, priority for filling forms
this.appOptions.canComments = false;

View file

@ -659,7 +659,7 @@ define([
var licType = params.asc_getLicenseType();
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS
|| (licType===Asc.c_oLicenseResult.SuccessLimit || licType===Asc.c_oLicenseResult.ExpiredLimited) && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
|| licType===Asc.c_oLicenseResult.SuccessLimit && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
this._state.licenseType = licType;
if (this._isDocReady && this._state.licenseType)
@ -768,6 +768,8 @@ define([
});
return;
}
if (Asc.c_oLicenseResult.ExpiredLimited === licType)
me._state.licenseType = licType;
if ( me.onServerVersion(params.asc_getBuildVersion()) ) return;
@ -799,7 +801,7 @@ define([
me.appOptions.canEditStyles = me.appOptions.canLicense && me.appOptions.canEdit;
me.appOptions.canPrint = (me.permissions.print !== false);
me.appOptions.fileKey = me.document.key;
me.appOptions.canFillForms = ((me.permissions.fillForms===undefined) ? me.appOptions.isEdit : me.permissions.fillForms) && (me.editorConfig.mode !== 'view');
me.appOptions.canFillForms = me.appOptions.canLicense && ((me.permissions.fillForms===undefined) ? me.appOptions.isEdit : me.permissions.fillForms) && (me.editorConfig.mode !== 'view');
me.appOptions.isRestrictedEdit = !me.appOptions.isEdit && me.appOptions.canFillForms;
me.appOptions.trialMode = params.asc_getLicenseMode();

View file

@ -845,7 +845,7 @@ define([
var licType = params.asc_getLicenseType();
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS
|| (licType===Asc.c_oLicenseResult.SuccessLimit || licType===Asc.c_oLicenseResult.ExpiredLimited) && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
|| licType===Asc.c_oLicenseResult.SuccessLimit && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
this._state.licenseType = licType;
if (this._isDocReady)
@ -934,6 +934,8 @@ define([
});
return;
}
if (Asc.c_oLicenseResult.ExpiredLimited === licType)
this._state.licenseType = licType;
if ( this.onServerVersion(params.asc_getBuildVersion()) ) return;

View file

@ -589,7 +589,7 @@ define([
var licType = params.asc_getLicenseType();
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS
|| (licType===Asc.c_oLicenseResult.SuccessLimit || licType===Asc.c_oLicenseResult.ExpiredLimited) && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
|| licType===Asc.c_oLicenseResult.SuccessLimit && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
this._state.licenseType = licType;
if (this._isDocReady && this._state.licenseType)
@ -698,6 +698,8 @@ define([
});
return;
}
if (Asc.c_oLicenseResult.ExpiredLimited === licType)
me._state.licenseType = licType;
if ( me.onServerVersion(params.asc_getBuildVersion()) ) return;

View file

@ -912,7 +912,7 @@ define([
var licType = params.asc_getLicenseType();
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS
|| (licType===Asc.c_oLicenseResult.SuccessLimit || licType===Asc.c_oLicenseResult.ExpiredLimited) && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
|| licType===Asc.c_oLicenseResult.SuccessLimit && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
this._state.licenseType = licType;
if (this._isDocReady)
@ -1001,6 +1001,8 @@ define([
});
return;
}
if (Asc.c_oLicenseResult.ExpiredLimited === licType)
this._state.licenseType = licType;
if ( this.onServerVersion(params.asc_getBuildVersion()) ) return;

View file

@ -615,7 +615,7 @@ define([
var licType = params.asc_getLicenseType();
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS
|| (licType===Asc.c_oLicenseResult.SuccessLimit || licType===Asc.c_oLicenseResult.ExpiredLimited) && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
|| licType===Asc.c_oLicenseResult.SuccessLimit && (this.appOptions.trialMode & Asc.c_oLicenseMode.Limited) !== 0))
this._state.licenseType = licType;
if (this._isDocReady && this._state.licenseType)
@ -724,6 +724,8 @@ define([
});
return;
}
if (Asc.c_oLicenseResult.ExpiredLimited === licType)
me._state.licenseType = licType;
if ( me.onServerVersion(params.asc_getBuildVersion()) ) return;