Add license type ConnectionsOS, UsersCountOS
This commit is contained in:
parent
43af68c439
commit
0d49651ea7
|
@ -108,7 +108,7 @@ define([
|
||||||
weakCompare : function(obj1, obj2){return obj1.type === obj2.type;}
|
weakCompare : function(obj1, obj2){return obj1.type === obj2.type;}
|
||||||
});
|
});
|
||||||
|
|
||||||
this._state = {isDisconnected: false, usersCount: 1, fastCoauth: true, lostEditingRights: false, licenseWarning: false};
|
this._state = {isDisconnected: false, usersCount: 1, fastCoauth: true, lostEditingRights: false, licenseType: false};
|
||||||
this.languages = null;
|
this.languages = null;
|
||||||
this.translationTable = [];
|
this.translationTable = [];
|
||||||
// Initialize viewport
|
// Initialize viewport
|
||||||
|
@ -994,16 +994,27 @@ define([
|
||||||
|
|
||||||
onLicenseChanged: function(params) {
|
onLicenseChanged: function(params) {
|
||||||
var licType = params.asc_getLicenseType();
|
var licType = params.asc_getLicenseType();
|
||||||
if (licType !== undefined && (licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount) && this.appOptions.canEdit && this.editorConfig.mode !== 'view') {
|
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
|
||||||
this._state.licenseWarning = (licType===Asc.c_oLicenseResult.Connections) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS))
|
||||||
}
|
this._state.licenseType = licType;
|
||||||
|
|
||||||
if (this._isDocReady)
|
if (this._isDocReady)
|
||||||
this.applyLicense();
|
this.applyLicense();
|
||||||
},
|
},
|
||||||
|
|
||||||
applyLicense: function() {
|
applyLicense: function() {
|
||||||
if (this._state.licenseWarning) {
|
if (this._state.licenseType) {
|
||||||
|
var license = this._state.licenseType,
|
||||||
|
buttons = ['ok'],
|
||||||
|
primary = 'ok';
|
||||||
|
if (license===Asc.c_oLicenseResult.Connections || license===Asc.c_oLicenseResult.UsersCount) {
|
||||||
|
license = (license===Asc.c_oLicenseResult.Connections) ? this.warnLicenseExceeded : this.warnLicenseUsersExceeded;
|
||||||
|
} else {
|
||||||
|
license = (license===Asc.c_oLicenseResult.ConnectionsOS) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
||||||
|
buttons = [{value: 'buynow', caption: this.textBuyNow}, {value: 'contact', caption: this.textContactUs}];
|
||||||
|
primary = 'buynow';
|
||||||
|
}
|
||||||
|
|
||||||
this.disableEditing(true);
|
this.disableEditing(true);
|
||||||
Common.NotificationCenter.trigger('api:disconnect');
|
Common.NotificationCenter.trigger('api:disconnect');
|
||||||
|
|
||||||
|
@ -1015,12 +1026,9 @@ define([
|
||||||
Common.UI.info({
|
Common.UI.info({
|
||||||
width: 500,
|
width: 500,
|
||||||
title: this.textNoLicenseTitle,
|
title: this.textNoLicenseTitle,
|
||||||
msg : this._state.licenseWarning,
|
msg : license,
|
||||||
buttons: [
|
buttons: buttons,
|
||||||
{value: 'buynow', caption: this.textBuyNow},
|
primary: primary,
|
||||||
{value: 'contact', caption: this.textContactUs}
|
|
||||||
],
|
|
||||||
primary: 'buynow',
|
|
||||||
callback: function(btn) {
|
callback: function(btn) {
|
||||||
if (btn == 'buynow')
|
if (btn == 'buynow')
|
||||||
window.open('https://www.onlyoffice.com', "_blank");
|
window.open('https://www.onlyoffice.com', "_blank");
|
||||||
|
@ -2192,7 +2200,6 @@ define([
|
||||||
txtErrorLoadHistory: 'Loading history failed',
|
txtErrorLoadHistory: 'Loading history failed',
|
||||||
textBuyNow: 'Visit website',
|
textBuyNow: 'Visit website',
|
||||||
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
||||||
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
textContactUs: 'Contact sales',
|
textContactUs: 'Contact sales',
|
||||||
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download or print until the connection is restored.',
|
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download or print until the connection is restored.',
|
||||||
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
||||||
|
@ -2240,10 +2247,13 @@ define([
|
||||||
txtOddPage: "Odd Page ",
|
txtOddPage: "Odd Page ",
|
||||||
txtSameAsPrev: "Same as Previous",
|
txtSameAsPrev: "Same as Previous",
|
||||||
txtCurrentDocument: "Current Document",
|
txtCurrentDocument: "Current Document",
|
||||||
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
txtNoTableOfContents: "No table of contents entries found.",
|
txtNoTableOfContents: "No table of contents entries found.",
|
||||||
txtTableOfContents: "Table of Contents",
|
txtTableOfContents: "Table of Contents",
|
||||||
errorForceSave: "An error occurred while saving the file. Please use the 'Download as' option to save the file to your computer hard drive or try again later."
|
errorForceSave: "An error occurred while saving the file. Please use the 'Download as' option to save the file to your computer hard drive or try again later.",
|
||||||
|
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnLicenseExceeded: 'The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.',
|
||||||
|
warnLicenseUsersExceeded: 'The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.'
|
||||||
}
|
}
|
||||||
})(), DE.Controllers.Main || {}))
|
})(), DE.Controllers.Main || {}))
|
||||||
});
|
});
|
|
@ -447,8 +447,10 @@
|
||||||
"DE.Controllers.Main.warnBrowserIE9": "The application has low capabilities on IE9. Use IE10 or higher",
|
"DE.Controllers.Main.warnBrowserIE9": "The application has low capabilities on IE9. Use IE10 or higher",
|
||||||
"DE.Controllers.Main.warnBrowserZoom": "Your browser current zoom setting is not fully supported. Please reset to the default zoom by pressing Ctrl+0.",
|
"DE.Controllers.Main.warnBrowserZoom": "Your browser current zoom setting is not fully supported. Please reset to the default zoom by pressing Ctrl+0.",
|
||||||
"DE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
"DE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
||||||
"DE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"DE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.",
|
||||||
"DE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"DE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.",
|
||||||
|
"DE.Controllers.Main.warnLicenseExceeded": "The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
|
"DE.Controllers.Main.warnLicenseUsersExceeded": "The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
"DE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
"DE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
||||||
"DE.Controllers.Navigation.txtBeginning": "Beginning of document",
|
"DE.Controllers.Navigation.txtBeginning": "Beginning of document",
|
||||||
"DE.Controllers.Navigation.txtGotoBeginning": "Go to the beginning of the document",
|
"DE.Controllers.Navigation.txtGotoBeginning": "Go to the beginning of the document",
|
||||||
|
|
|
@ -80,7 +80,7 @@ define([
|
||||||
usersCount : 1,
|
usersCount : 1,
|
||||||
fastCoauth : true,
|
fastCoauth : true,
|
||||||
lostEditingRights : false,
|
lostEditingRights : false,
|
||||||
licenseWarning : false
|
licenseType : false
|
||||||
};
|
};
|
||||||
|
|
||||||
// Initialize viewport
|
// Initialize viewport
|
||||||
|
@ -568,17 +568,37 @@ define([
|
||||||
|
|
||||||
onLicenseChanged: function(params) {
|
onLicenseChanged: function(params) {
|
||||||
var licType = params.asc_getLicenseType();
|
var licType = params.asc_getLicenseType();
|
||||||
if (licType !== undefined && (licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount) && this.appOptions.canEdit && this.editorConfig.mode !== 'view') {
|
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
|
||||||
this._state.licenseWarning = (licType===Asc.c_oLicenseResult.Connections) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS))
|
||||||
}
|
this._state.licenseType = licType;
|
||||||
|
|
||||||
if (this._isDocReady && this._state.licenseWarning)
|
if (this._isDocReady && this._state.licenseType)
|
||||||
this.applyLicense();
|
this.applyLicense();
|
||||||
},
|
},
|
||||||
|
|
||||||
applyLicense: function() {
|
applyLicense: function() {
|
||||||
var me = this;
|
var me = this;
|
||||||
if (me._state.licenseWarning) {
|
if (this._state.licenseType) {
|
||||||
|
var license = this._state.licenseType,
|
||||||
|
buttons = [{text: 'OK'}];
|
||||||
|
if (license===Asc.c_oLicenseResult.Connections || license===Asc.c_oLicenseResult.UsersCount) {
|
||||||
|
license = (license===Asc.c_oLicenseResult.Connections) ? this.warnLicenseExceeded : this.warnLicenseUsersExceeded;
|
||||||
|
} else {
|
||||||
|
license = (license===Asc.c_oLicenseResult.ConnectionsOS) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
||||||
|
buttons = [{
|
||||||
|
text: me.textBuyNow,
|
||||||
|
bold: true,
|
||||||
|
onClick: function() {
|
||||||
|
window.open('https://www.onlyoffice.com', "_blank");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
text: me.textContactUs,
|
||||||
|
onClick: function() {
|
||||||
|
window.open('mailto:sales@onlyoffice.com', "_blank");
|
||||||
|
}
|
||||||
|
}];
|
||||||
|
}
|
||||||
DE.getController('Toolbar').activateViewControls();
|
DE.getController('Toolbar').activateViewControls();
|
||||||
DE.getController('Toolbar').deactivateEditControls();
|
DE.getController('Toolbar').deactivateEditControls();
|
||||||
Common.NotificationCenter.trigger('api:disconnect');
|
Common.NotificationCenter.trigger('api:disconnect');
|
||||||
|
@ -591,22 +611,8 @@ define([
|
||||||
Common.localStorage.setItem("de-license-warning", now);
|
Common.localStorage.setItem("de-license-warning", now);
|
||||||
uiApp.modal({
|
uiApp.modal({
|
||||||
title: me.textNoLicenseTitle,
|
title: me.textNoLicenseTitle,
|
||||||
text : me._state.licenseWarning,
|
text : license,
|
||||||
buttons: [
|
buttons: buttons
|
||||||
{
|
|
||||||
text: me.textBuyNow,
|
|
||||||
bold: true,
|
|
||||||
onClick: function() {
|
|
||||||
window.open('https://www.onlyoffice.com', "_blank");
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: me.textContactUs,
|
|
||||||
onClick: function() {
|
|
||||||
window.open('mailto:sales@onlyoffice.com', "_blank");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
|
@ -1251,7 +1257,6 @@ define([
|
||||||
textTryUndoRedo: 'The Undo/Redo functions are disabled for the Fast co-editing mode.',
|
textTryUndoRedo: 'The Undo/Redo functions are disabled for the Fast co-editing mode.',
|
||||||
textBuyNow: 'Visit website',
|
textBuyNow: 'Visit website',
|
||||||
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
||||||
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
textContactUs: 'Contact sales',
|
textContactUs: 'Contact sales',
|
||||||
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download until the connection is restored.',
|
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download until the connection is restored.',
|
||||||
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
||||||
|
@ -1292,8 +1297,11 @@ define([
|
||||||
txtStyle_footnote_text: 'Footnote Text',
|
txtStyle_footnote_text: 'Footnote Text',
|
||||||
txtHeader: "Header",
|
txtHeader: "Header",
|
||||||
txtFooter: "Footer",
|
txtFooter: "Footer",
|
||||||
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
txtProtected: 'Once you enter the password and open the file, the current password to the file will be reset',
|
||||||
txtProtected: 'Once you enter the password and open the file, the current password to the file will be reset'
|
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnLicenseExceeded: 'The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.',
|
||||||
|
warnLicenseUsersExceeded: 'The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.'
|
||||||
}
|
}
|
||||||
})(), DE.Controllers.Main || {}))
|
})(), DE.Controllers.Main || {}))
|
||||||
});
|
});
|
|
@ -150,8 +150,10 @@
|
||||||
"DE.Controllers.Main.uploadImageTextText": "Uploading image...",
|
"DE.Controllers.Main.uploadImageTextText": "Uploading image...",
|
||||||
"DE.Controllers.Main.uploadImageTitleText": "Uploading Image",
|
"DE.Controllers.Main.uploadImageTitleText": "Uploading Image",
|
||||||
"DE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
"DE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
||||||
"DE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"DE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.",
|
||||||
"DE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"DE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.",
|
||||||
|
"DE.Controllers.Main.warnLicenseExceeded": "The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
|
"DE.Controllers.Main.warnLicenseUsersExceeded": "The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
"DE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
"DE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
||||||
"DE.Controllers.Search.textNoTextFound": "Text not Found",
|
"DE.Controllers.Search.textNoTextFound": "Text not Found",
|
||||||
"DE.Controllers.Search.textReplaceAll": "Replace All",
|
"DE.Controllers.Search.textReplaceAll": "Replace All",
|
||||||
|
|
|
@ -102,7 +102,7 @@ define([
|
||||||
onLaunch: function() {
|
onLaunch: function() {
|
||||||
var me = this;
|
var me = this;
|
||||||
|
|
||||||
this._state = {isDisconnected: false, usersCount: 1, fastCoauth: true, lostEditingRights: false, licenseWarning: false};
|
this._state = {isDisconnected: false, usersCount: 1, fastCoauth: true, lostEditingRights: false, licenseType: false};
|
||||||
this.languages = null;
|
this.languages = null;
|
||||||
this.translationTable = [];
|
this.translationTable = [];
|
||||||
|
|
||||||
|
@ -759,16 +759,27 @@ define([
|
||||||
|
|
||||||
onLicenseChanged: function(params) {
|
onLicenseChanged: function(params) {
|
||||||
var licType = params.asc_getLicenseType();
|
var licType = params.asc_getLicenseType();
|
||||||
if (licType !== undefined && (licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount) && this.appOptions.canEdit && this.editorConfig.mode !== 'view') {
|
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
|
||||||
this._state.licenseWarning = (licType===Asc.c_oLicenseResult.Connections) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS))
|
||||||
}
|
this._state.licenseType = licType;
|
||||||
|
|
||||||
if (this._isDocReady)
|
if (this._isDocReady)
|
||||||
this.applyLicense();
|
this.applyLicense();
|
||||||
},
|
},
|
||||||
|
|
||||||
applyLicense: function() {
|
applyLicense: function() {
|
||||||
if (this._state.licenseWarning) {
|
if (this._state.licenseType) {
|
||||||
|
var license = this._state.licenseType,
|
||||||
|
buttons = ['ok'],
|
||||||
|
primary = 'ok';
|
||||||
|
if (license===Asc.c_oLicenseResult.Connections || license===Asc.c_oLicenseResult.UsersCount) {
|
||||||
|
license = (license===Asc.c_oLicenseResult.Connections) ? this.warnLicenseExceeded : this.warnLicenseUsersExceeded;
|
||||||
|
} else {
|
||||||
|
license = (license===Asc.c_oLicenseResult.ConnectionsOS) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
||||||
|
buttons = [{value: 'buynow', caption: this.textBuyNow}, {value: 'contact', caption: this.textContactUs}];
|
||||||
|
primary = 'buynow';
|
||||||
|
}
|
||||||
|
|
||||||
this.disableEditing(true);
|
this.disableEditing(true);
|
||||||
Common.NotificationCenter.trigger('api:disconnect');
|
Common.NotificationCenter.trigger('api:disconnect');
|
||||||
|
|
||||||
|
@ -780,12 +791,9 @@ define([
|
||||||
Common.UI.info({
|
Common.UI.info({
|
||||||
width: 500,
|
width: 500,
|
||||||
title: this.textNoLicenseTitle,
|
title: this.textNoLicenseTitle,
|
||||||
msg : this._state.licenseWarning,
|
msg : license,
|
||||||
buttons: [
|
buttons: buttons,
|
||||||
{value: 'buynow', caption: this.textBuyNow},
|
primary: primary,
|
||||||
{value: 'contact', caption: this.textContactUs}
|
|
||||||
],
|
|
||||||
primary: 'buynow',
|
|
||||||
callback: function(btn) {
|
callback: function(btn) {
|
||||||
if (btn == 'buynow')
|
if (btn == 'buynow')
|
||||||
window.open('https://www.onlyoffice.com', "_blank");
|
window.open('https://www.onlyoffice.com', "_blank");
|
||||||
|
@ -1977,7 +1985,6 @@ define([
|
||||||
textStrict: 'Strict mode',
|
textStrict: 'Strict mode',
|
||||||
textBuyNow: 'Visit website',
|
textBuyNow: 'Visit website',
|
||||||
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
||||||
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
textContactUs: 'Contact sales',
|
textContactUs: 'Contact sales',
|
||||||
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download or print until the connection is restored.',
|
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download or print until the connection is restored.',
|
||||||
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
||||||
|
@ -2010,7 +2017,6 @@ define([
|
||||||
saveTextText: 'Saving document...',
|
saveTextText: 'Saving document...',
|
||||||
txtLoading: 'Loading...',
|
txtLoading: 'Loading...',
|
||||||
txtAddNotes: 'Click to add notes',
|
txtAddNotes: 'Click to add notes',
|
||||||
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
errorForceSave: "An error occurred while saving the file. Please use the 'Download as' option to save the file to your computer hard drive or try again later.",
|
errorForceSave: "An error occurred while saving the file. Please use the 'Download as' option to save the file to your computer hard drive or try again later.",
|
||||||
txtAddFirstSlide: 'Click to add first slide',
|
txtAddFirstSlide: 'Click to add first slide',
|
||||||
txtTheme_blank: 'Blank',
|
txtTheme_blank: 'Blank',
|
||||||
|
@ -2023,7 +2029,11 @@ define([
|
||||||
txtTheme_safari: 'Safari',
|
txtTheme_safari: 'Safari',
|
||||||
txtTheme_dotted: 'Dotted',
|
txtTheme_dotted: 'Dotted',
|
||||||
txtTheme_corner: 'Corner',
|
txtTheme_corner: 'Corner',
|
||||||
txtTheme_turtle: 'Turtle'
|
txtTheme_turtle: 'Turtle',
|
||||||
|
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnLicenseExceeded: 'The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.',
|
||||||
|
warnLicenseUsersExceeded: 'The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.'
|
||||||
}
|
}
|
||||||
})(), PE.Controllers.Main || {}))
|
})(), PE.Controllers.Main || {}))
|
||||||
});
|
});
|
||||||
|
|
|
@ -386,8 +386,10 @@
|
||||||
"PE.Controllers.Main.warnBrowserIE9": "The application has low capabilities on IE9. Use IE10 or higher",
|
"PE.Controllers.Main.warnBrowserIE9": "The application has low capabilities on IE9. Use IE10 or higher",
|
||||||
"PE.Controllers.Main.warnBrowserZoom": "Your browser current zoom setting is not fully supported. Please reset to the default zoom by pressing Ctrl+0.",
|
"PE.Controllers.Main.warnBrowserZoom": "Your browser current zoom setting is not fully supported. Please reset to the default zoom by pressing Ctrl+0.",
|
||||||
"PE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
"PE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
||||||
"PE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"PE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.",
|
||||||
"PE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"PE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.",
|
||||||
|
"PE.Controllers.Main.warnLicenseExceeded": "The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
|
"PE.Controllers.Main.warnLicenseUsersExceeded": "The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
"PE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
"PE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
||||||
"PE.Controllers.Statusbar.zoomText": "Zoom {0}%",
|
"PE.Controllers.Statusbar.zoomText": "Zoom {0}%",
|
||||||
"PE.Controllers.Toolbar.confirmAddFontName": "The font you are going to save is not available on the current device.<br>The text style will be displayed using one of the system fonts, the saved font will be used when it is available.<br>Do you want to continue?",
|
"PE.Controllers.Toolbar.confirmAddFontName": "The font you are going to save is not available on the current device.<br>The text style will be displayed using one of the system fonts, the saved font will be used when it is available.<br>Do you want to continue?",
|
||||||
|
|
|
@ -80,7 +80,7 @@ define([
|
||||||
usersCount : 1,
|
usersCount : 1,
|
||||||
fastCoauth : true,
|
fastCoauth : true,
|
||||||
lostEditingRights : false,
|
lostEditingRights : false,
|
||||||
licenseWarning : false
|
licenseType : false
|
||||||
};
|
};
|
||||||
|
|
||||||
// Initialize viewport
|
// Initialize viewport
|
||||||
|
@ -523,17 +523,37 @@ define([
|
||||||
|
|
||||||
onLicenseChanged: function(params) {
|
onLicenseChanged: function(params) {
|
||||||
var licType = params.asc_getLicenseType();
|
var licType = params.asc_getLicenseType();
|
||||||
if (licType !== undefined && (licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount) && this.appOptions.canEdit && this.editorConfig.mode !== 'view') {
|
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
|
||||||
this._state.licenseWarning = (licType===Asc.c_oLicenseResult.Connections) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS))
|
||||||
}
|
this._state.licenseType = licType;
|
||||||
|
|
||||||
if (this._isDocReady && this._state.licenseWarning)
|
if (this._isDocReady && this._state.licenseType)
|
||||||
this.applyLicense();
|
this.applyLicense();
|
||||||
},
|
},
|
||||||
|
|
||||||
applyLicense: function() {
|
applyLicense: function() {
|
||||||
var me = this;
|
var me = this;
|
||||||
if (me._state.licenseWarning) {
|
if (this._state.licenseType) {
|
||||||
|
var license = this._state.licenseType,
|
||||||
|
buttons = [{text: 'OK'}];
|
||||||
|
if (license===Asc.c_oLicenseResult.Connections || license===Asc.c_oLicenseResult.UsersCount) {
|
||||||
|
license = (license===Asc.c_oLicenseResult.Connections) ? this.warnLicenseExceeded : this.warnLicenseUsersExceeded;
|
||||||
|
} else {
|
||||||
|
license = (license===Asc.c_oLicenseResult.ConnectionsOS) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
||||||
|
buttons = [{
|
||||||
|
text: me.textBuyNow,
|
||||||
|
bold: true,
|
||||||
|
onClick: function() {
|
||||||
|
window.open('https://www.onlyoffice.com', "_blank");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
text: me.textContactUs,
|
||||||
|
onClick: function() {
|
||||||
|
window.open('mailto:sales@onlyoffice.com', "_blank");
|
||||||
|
}
|
||||||
|
}];
|
||||||
|
}
|
||||||
PE.getController('Toolbar').activateViewControls();
|
PE.getController('Toolbar').activateViewControls();
|
||||||
PE.getController('Toolbar').deactivateEditControls();
|
PE.getController('Toolbar').deactivateEditControls();
|
||||||
Common.NotificationCenter.trigger('api:disconnect');
|
Common.NotificationCenter.trigger('api:disconnect');
|
||||||
|
@ -546,22 +566,8 @@ define([
|
||||||
Common.localStorage.setItem("pe-license-warning", now);
|
Common.localStorage.setItem("pe-license-warning", now);
|
||||||
uiApp.modal({
|
uiApp.modal({
|
||||||
title: me.textNoLicenseTitle,
|
title: me.textNoLicenseTitle,
|
||||||
text : me._state.licenseWarning,
|
text : license,
|
||||||
buttons: [
|
buttons: buttons
|
||||||
{
|
|
||||||
text: me.textBuyNow,
|
|
||||||
bold: true,
|
|
||||||
onClick: function() {
|
|
||||||
window.open('https://www.onlyoffice.com', "_blank");
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: me.textContactUs,
|
|
||||||
onClick: function() {
|
|
||||||
window.open('mailto:sales@onlyoffice.com', "_blank");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
|
@ -1252,7 +1258,6 @@ define([
|
||||||
textTryUndoRedo: 'The Undo/Redo functions are disabled for the Fast co-editing mode.',
|
textTryUndoRedo: 'The Undo/Redo functions are disabled for the Fast co-editing mode.',
|
||||||
textBuyNow: 'Visit website',
|
textBuyNow: 'Visit website',
|
||||||
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
||||||
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
textContactUs: 'Contact sales',
|
textContactUs: 'Contact sales',
|
||||||
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download or print until the connection is restored.',
|
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download or print until the connection is restored.',
|
||||||
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
||||||
|
@ -1285,8 +1290,11 @@ define([
|
||||||
txtSlideNumber: 'Slide number',
|
txtSlideNumber: 'Slide number',
|
||||||
txtSlideSubtitle: 'Slide subtitle',
|
txtSlideSubtitle: 'Slide subtitle',
|
||||||
txtSlideTitle: 'Slide title',
|
txtSlideTitle: 'Slide title',
|
||||||
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
txtProtected: 'Once you enter the password and open the file, the current password to the file will be reset',
|
||||||
txtProtected: 'Once you enter the password and open the file, the current password to the file will be reset'
|
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnLicenseExceeded: 'The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.',
|
||||||
|
warnLicenseUsersExceeded: 'The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.'
|
||||||
}
|
}
|
||||||
})(), PE.Controllers.Main || {}))
|
})(), PE.Controllers.Main || {}))
|
||||||
});
|
});
|
|
@ -204,8 +204,10 @@
|
||||||
"PE.Controllers.Main.uploadImageTextText": "Uploading image...",
|
"PE.Controllers.Main.uploadImageTextText": "Uploading image...",
|
||||||
"PE.Controllers.Main.uploadImageTitleText": "Uploading Image",
|
"PE.Controllers.Main.uploadImageTitleText": "Uploading Image",
|
||||||
"PE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
"PE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
||||||
"PE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"PE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.",
|
||||||
"PE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"PE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.",
|
||||||
|
"PE.Controllers.Main.warnLicenseExceeded": "The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
|
"PE.Controllers.Main.warnLicenseUsersExceeded": "The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
"PE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
"PE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
||||||
"PE.Controllers.Search.textNoTextFound": "Text not Found",
|
"PE.Controllers.Search.textNoTextFound": "Text not Found",
|
||||||
"PE.Controllers.Settings.notcriticalErrorTitle": "Warning",
|
"PE.Controllers.Settings.notcriticalErrorTitle": "Warning",
|
||||||
|
|
|
@ -107,7 +107,7 @@ define([
|
||||||
// $(document.body).css('position', 'absolute');
|
// $(document.body).css('position', 'absolute');
|
||||||
var me = this;
|
var me = this;
|
||||||
|
|
||||||
this._state = {isDisconnected: false, usersCount: 1, fastCoauth: true, lostEditingRights: false, licenseWarning: false};
|
this._state = {isDisconnected: false, usersCount: 1, fastCoauth: true, lostEditingRights: false, licenseType: false};
|
||||||
this.translationTable = [];
|
this.translationTable = [];
|
||||||
|
|
||||||
if (!Common.Utils.isBrowserSupported()){
|
if (!Common.Utils.isBrowserSupported()){
|
||||||
|
@ -786,16 +786,27 @@ define([
|
||||||
if (this.appOptions.isEditDiagram || this.appOptions.isEditMailMerge) return;
|
if (this.appOptions.isEditDiagram || this.appOptions.isEditMailMerge) return;
|
||||||
|
|
||||||
var licType = params.asc_getLicenseType();
|
var licType = params.asc_getLicenseType();
|
||||||
if (licType !== undefined && (licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount) && this.appOptions.canEdit && this.editorConfig.mode !== 'view') {
|
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
|
||||||
this._state.licenseWarning = (licType===Asc.c_oLicenseResult.Connections) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS))
|
||||||
}
|
this._state.licenseType = licType;
|
||||||
|
|
||||||
if (this._isDocReady)
|
if (this._isDocReady)
|
||||||
this.applyLicense();
|
this.applyLicense();
|
||||||
},
|
},
|
||||||
|
|
||||||
applyLicense: function() {
|
applyLicense: function() {
|
||||||
if (this._state.licenseWarning) {
|
if (this._state.licenseType) {
|
||||||
|
var license = this._state.licenseType,
|
||||||
|
buttons = ['ok'],
|
||||||
|
primary = 'ok';
|
||||||
|
if (license===Asc.c_oLicenseResult.Connections || license===Asc.c_oLicenseResult.UsersCount) {
|
||||||
|
license = (license===Asc.c_oLicenseResult.Connections) ? this.warnLicenseExceeded : this.warnLicenseUsersExceeded;
|
||||||
|
} else {
|
||||||
|
license = (license===Asc.c_oLicenseResult.ConnectionsOS) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
||||||
|
buttons = [{value: 'buynow', caption: this.textBuyNow}, {value: 'contact', caption: this.textContactUs}];
|
||||||
|
primary = 'buynow';
|
||||||
|
}
|
||||||
|
|
||||||
this.disableEditing(true);
|
this.disableEditing(true);
|
||||||
Common.NotificationCenter.trigger('api:disconnect');
|
Common.NotificationCenter.trigger('api:disconnect');
|
||||||
|
|
||||||
|
@ -807,12 +818,9 @@ define([
|
||||||
Common.UI.info({
|
Common.UI.info({
|
||||||
width: 500,
|
width: 500,
|
||||||
title: this.textNoLicenseTitle,
|
title: this.textNoLicenseTitle,
|
||||||
msg : this._state.licenseWarning,
|
msg : license,
|
||||||
buttons: [
|
buttons: buttons,
|
||||||
{value: 'buynow', caption: this.textBuyNow},
|
primary: primary,
|
||||||
{value: 'contact', caption: this.textContactUs}
|
|
||||||
],
|
|
||||||
primary: 'buynow',
|
|
||||||
callback: function(btn) {
|
callback: function(btn) {
|
||||||
if (btn == 'buynow')
|
if (btn == 'buynow')
|
||||||
window.open('https://www.onlyoffice.com', "_blank");
|
window.open('https://www.onlyoffice.com', "_blank");
|
||||||
|
@ -2159,7 +2167,6 @@ define([
|
||||||
errorFrmlWrongReferences: 'The function refers to a sheet that does not exist.<br>Please check the data and try again.',
|
errorFrmlWrongReferences: 'The function refers to a sheet that does not exist.<br>Please check the data and try again.',
|
||||||
textBuyNow: 'Visit website',
|
textBuyNow: 'Visit website',
|
||||||
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
||||||
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
textContactUs: 'Contact sales',
|
textContactUs: 'Contact sales',
|
||||||
confirmPutMergeRange: 'The source data contains merged cells.<br>They will be unmerged before they are pasted into the table.',
|
confirmPutMergeRange: 'The source data contains merged cells.<br>They will be unmerged before they are pasted into the table.',
|
||||||
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download or print until the connection is restored.',
|
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download or print until the connection is restored.',
|
||||||
|
@ -2200,9 +2207,13 @@ define([
|
||||||
txtStyle_Currency: 'Currency',
|
txtStyle_Currency: 'Currency',
|
||||||
txtStyle_Percent: 'Percent',
|
txtStyle_Percent: 'Percent',
|
||||||
txtStyle_Comma: 'Comma',
|
txtStyle_Comma: 'Comma',
|
||||||
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
errorForceSave: "An error occurred while saving the file. Please use the 'Download as' option to save the file to your computer hard drive or try again later.",
|
errorForceSave: "An error occurred while saving the file. Please use the 'Download as' option to save the file to your computer hard drive or try again later.",
|
||||||
errorMaxPoints: "The maximum number of points in series per chart is 4096."
|
errorMaxPoints: "The maximum number of points in series per chart is 4096.",
|
||||||
|
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnLicenseExceeded: 'The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.',
|
||||||
|
warnLicenseUsersExceeded: 'The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.'
|
||||||
|
|
||||||
}
|
}
|
||||||
})(), SSE.Controllers.Main || {}))
|
})(), SSE.Controllers.Main || {}))
|
||||||
});
|
});
|
||||||
|
|
|
@ -495,8 +495,10 @@
|
||||||
"SSE.Controllers.Main.warnBrowserIE9": "The application has low capabilities on IE9. Use IE10 or higher",
|
"SSE.Controllers.Main.warnBrowserIE9": "The application has low capabilities on IE9. Use IE10 or higher",
|
||||||
"SSE.Controllers.Main.warnBrowserZoom": "Your browser current zoom setting is not fully supported. Please reset to the default zoom by pressing Ctrl+0.",
|
"SSE.Controllers.Main.warnBrowserZoom": "Your browser current zoom setting is not fully supported. Please reset to the default zoom by pressing Ctrl+0.",
|
||||||
"SSE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
"SSE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
||||||
"SSE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"SSE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.",
|
||||||
"SSE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"SSE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.",
|
||||||
|
"SSE.Controllers.Main.warnLicenseExceeded": "The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
|
"SSE.Controllers.Main.warnLicenseUsersExceeded": "The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
"SSE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
"SSE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
||||||
"SSE.Controllers.Print.strAllSheets": "All Sheets",
|
"SSE.Controllers.Print.strAllSheets": "All Sheets",
|
||||||
"SSE.Controllers.Print.textWarning": "Warning",
|
"SSE.Controllers.Print.textWarning": "Warning",
|
||||||
|
|
|
@ -81,7 +81,7 @@ define([
|
||||||
usersCount : 1,
|
usersCount : 1,
|
||||||
fastCoauth : true,
|
fastCoauth : true,
|
||||||
lostEditingRights : false,
|
lostEditingRights : false,
|
||||||
licenseWarning : false
|
licenseType : false
|
||||||
};
|
};
|
||||||
|
|
||||||
// Initialize viewport
|
// Initialize viewport
|
||||||
|
@ -552,17 +552,37 @@ define([
|
||||||
if (this.appOptions.isEditDiagram || this.appOptions.isEditMailMerge) return;
|
if (this.appOptions.isEditDiagram || this.appOptions.isEditMailMerge) return;
|
||||||
|
|
||||||
var licType = params.asc_getLicenseType();
|
var licType = params.asc_getLicenseType();
|
||||||
if (licType !== undefined && (licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount) && this.appOptions.canEdit && this.editorConfig.mode !== 'view') {
|
if (licType !== undefined && this.appOptions.canEdit && this.editorConfig.mode !== 'view' &&
|
||||||
this._state.licenseWarning = (licType===Asc.c_oLicenseResult.Connections) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
(licType===Asc.c_oLicenseResult.Connections || licType===Asc.c_oLicenseResult.UsersCount || licType===Asc.c_oLicenseResult.ConnectionsOS || licType===Asc.c_oLicenseResult.UsersCountOS))
|
||||||
}
|
this._state.licenseType = licType;
|
||||||
|
|
||||||
if (this._isDocReady && this._state.licenseWarning)
|
if (this._isDocReady && this._state.licenseType)
|
||||||
this.applyLicense();
|
this.applyLicense();
|
||||||
},
|
},
|
||||||
|
|
||||||
applyLicense: function() {
|
applyLicense: function() {
|
||||||
var me = this;
|
var me = this;
|
||||||
if (me._state.licenseWarning) {
|
if (this._state.licenseType) {
|
||||||
|
var license = this._state.licenseType,
|
||||||
|
buttons = [{text: 'OK'}];
|
||||||
|
if (license===Asc.c_oLicenseResult.Connections || license===Asc.c_oLicenseResult.UsersCount) {
|
||||||
|
license = (license===Asc.c_oLicenseResult.Connections) ? this.warnLicenseExceeded : this.warnLicenseUsersExceeded;
|
||||||
|
} else {
|
||||||
|
license = (license===Asc.c_oLicenseResult.ConnectionsOS) ? this.warnNoLicense : this.warnNoLicenseUsers;
|
||||||
|
buttons = [{
|
||||||
|
text: me.textBuyNow,
|
||||||
|
bold: true,
|
||||||
|
onClick: function() {
|
||||||
|
window.open('https://www.onlyoffice.com', "_blank");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
text: me.textContactUs,
|
||||||
|
onClick: function() {
|
||||||
|
window.open('mailto:sales@onlyoffice.com', "_blank");
|
||||||
|
}
|
||||||
|
}];
|
||||||
|
}
|
||||||
SSE.getController('Toolbar').activateViewControls();
|
SSE.getController('Toolbar').activateViewControls();
|
||||||
SSE.getController('Toolbar').deactivateEditControls();
|
SSE.getController('Toolbar').deactivateEditControls();
|
||||||
Common.NotificationCenter.trigger('api:disconnect');
|
Common.NotificationCenter.trigger('api:disconnect');
|
||||||
|
@ -575,22 +595,8 @@ define([
|
||||||
Common.localStorage.setItem("sse-license-warning", now);
|
Common.localStorage.setItem("sse-license-warning", now);
|
||||||
uiApp.modal({
|
uiApp.modal({
|
||||||
title: me.textNoLicenseTitle,
|
title: me.textNoLicenseTitle,
|
||||||
text : me._state.licenseWarning,
|
text : license,
|
||||||
buttons: [
|
buttons: buttons
|
||||||
{
|
|
||||||
text: me.textBuyNow,
|
|
||||||
bold: true,
|
|
||||||
onClick: function() {
|
|
||||||
window.open('https://www.onlyoffice.com', "_blank");
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
text: me.textContactUs,
|
|
||||||
onClick: function() {
|
|
||||||
window.open('mailto:sales@onlyoffice.com', "_blank");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
|
@ -1396,7 +1402,6 @@ define([
|
||||||
txtErrorLoadHistory: 'Loading history failed',
|
txtErrorLoadHistory: 'Loading history failed',
|
||||||
textBuyNow: 'Visit website',
|
textBuyNow: 'Visit website',
|
||||||
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
textNoLicenseTitle: 'ONLYOFFICE open source version',
|
||||||
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
textContactUs: 'Contact sales',
|
textContactUs: 'Contact sales',
|
||||||
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download until the connection is restored.',
|
errorViewerDisconnect: 'Connection is lost. You can still view the document,<br>but will not be able to download until the connection is restored.',
|
||||||
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
warnLicenseExp: 'Your license has expired.<br>Please update your license and refresh the page.',
|
||||||
|
@ -1449,9 +1454,12 @@ define([
|
||||||
txtStyle_Currency: 'Currency',
|
txtStyle_Currency: 'Currency',
|
||||||
txtStyle_Percent: 'Percent',
|
txtStyle_Percent: 'Percent',
|
||||||
txtStyle_Comma: 'Comma',
|
txtStyle_Comma: 'Comma',
|
||||||
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.',
|
|
||||||
errorMaxPoints: 'The maximum number of points in series per chart is 4096.',
|
errorMaxPoints: 'The maximum number of points in series per chart is 4096.',
|
||||||
txtProtected: 'Once you enter the password and open the file, the current password to the file will be reset'
|
txtProtected: 'Once you enter the password and open the file, the current password to the file will be reset',
|
||||||
|
warnNoLicense: 'This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnNoLicenseUsers: 'This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.',
|
||||||
|
warnLicenseExceeded: 'The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.',
|
||||||
|
warnLicenseUsersExceeded: 'The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.'
|
||||||
}
|
}
|
||||||
})(), SSE.Controllers.Main || {}))
|
})(), SSE.Controllers.Main || {}))
|
||||||
});
|
});
|
|
@ -257,8 +257,10 @@
|
||||||
"SSE.Controllers.Main.uploadImageTextText": "Uploading image...",
|
"SSE.Controllers.Main.uploadImageTextText": "Uploading image...",
|
||||||
"SSE.Controllers.Main.uploadImageTitleText": "Uploading Image",
|
"SSE.Controllers.Main.uploadImageTitleText": "Uploading Image",
|
||||||
"SSE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
"SSE.Controllers.Main.warnLicenseExp": "Your license has expired.<br>Please update your license and refresh the page.",
|
||||||
"SSE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"SSE.Controllers.Main.warnNoLicense": "This version of ONLYOFFICE Editors has certain limitations for concurrent connections to the document server.<br>If you need more please consider purchasing a commercial license.",
|
||||||
"SSE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider upgrading your current license or purchasing a commercial one.",
|
"SSE.Controllers.Main.warnNoLicenseUsers": "This version of ONLYOFFICE Editors has certain limitations for concurrent users.<br>If you need more please consider purchasing a commercial license.",
|
||||||
|
"SSE.Controllers.Main.warnLicenseExceeded": "The number of concurrent connections to the document server has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
|
"SSE.Controllers.Main.warnLicenseUsersExceeded": "The number of concurrent users has been exceeded and the document will be opened for viewing only.<br>Please contact your administrator for more information.",
|
||||||
"SSE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
"SSE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.",
|
||||||
"SSE.Controllers.Search.textNoTextFound": "Text not found",
|
"SSE.Controllers.Search.textNoTextFound": "Text not found",
|
||||||
"SSE.Controllers.Search.textReplaceAll": "Replace All",
|
"SSE.Controllers.Search.textReplaceAll": "Replace All",
|
||||||
|
|
Loading…
Reference in a new issue