From f9398c90bfdefd48206eee6dc8e6cd8f0d6aecad Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Fri, 24 Jan 2025 14:28:20 +0300 Subject: [PATCH] [DE] Add error for protected range --- apps/documenteditor/main/app/controller/Main.js | 5 +++++ apps/documenteditor/main/locale/en.json | 1 + apps/documenteditor/mobile/locale/en.json | 1 + apps/documenteditor/mobile/src/controller/Error.jsx | 4 ++++ 4 files changed, 11 insertions(+) diff --git a/apps/documenteditor/main/app/controller/Main.js b/apps/documenteditor/main/app/controller/Main.js index 27464d90c2..f481d2f398 100644 --- a/apps/documenteditor/main/app/controller/Main.js +++ b/apps/documenteditor/main/app/controller/Main.js @@ -2300,6 +2300,11 @@ define([ config.msg = this.errorSaveWatermark; break; + case Asc.c_oAscError.ID.EditProtectedRange: + config.maxwidth = 600; + config.msg = this.errorEditProtectedRange; + break; + case Asc.c_oAscError.ID.ConvertationOpenFormat: config.maxwidth = 600; if (errData === 'pdf') diff --git a/apps/documenteditor/main/locale/en.json b/apps/documenteditor/main/locale/en.json index b4000f2ca2..8facc776eb 100644 --- a/apps/documenteditor/main/locale/en.json +++ b/apps/documenteditor/main/locale/en.json @@ -939,6 +939,7 @@ "DE.Controllers.Main.errorUserDrop": "The file cannot be accessed right now.", "DE.Controllers.Main.errorUsersExceed": "The number of users allowed by the pricing plan was exceeded", "DE.Controllers.Main.errorViewerDisconnect": "Connection is lost. You can still view the document,
but will not be able to download or print it until the connection is restored and page is reloaded.", + "DE.Controllers.Main.errorEditProtectedRange": "You are not allowed to edit this selection because it is protected.", "DE.Controllers.Main.leavePageText": "You have unsaved changes in this document. Click \"Stay on This Page\", then \"Save\" to save them. Click \"Leave This Page\" to discard all the unsaved changes.", "DE.Controllers.Main.leavePageTextOnClose": "All unsaved changes in this document will be lost.
Click \"Cancel\" then \"Save\" to save them. Click \"OK\" to discard all the unsaved changes.", "DE.Controllers.Main.loadFontsTextText": "Loading data...", diff --git a/apps/documenteditor/mobile/locale/en.json b/apps/documenteditor/mobile/locale/en.json index efb10a1102..ed423814c7 100644 --- a/apps/documenteditor/mobile/locale/en.json +++ b/apps/documenteditor/mobile/locale/en.json @@ -464,6 +464,7 @@ "errorUserDrop": "The file can't be accessed right now.", "errorUsersExceed": "The number of users allowed by the pricing plan was exceeded", "errorViewerDisconnect": "Connection is lost. You can still view the document,
but you won't be able to download or print it until the connection is restored and the page is reloaded.", + "errorEditProtectedRange": "You are not allowed to edit this selection because it is protected.", "notcriticalErrorTitle": "Warning", "openErrorText": "An error has occurred while opening the file", "saveErrorText": "An error has occurred while saving the file", diff --git a/apps/documenteditor/mobile/src/controller/Error.jsx b/apps/documenteditor/mobile/src/controller/Error.jsx index 3563215992..5fb4c19f00 100644 --- a/apps/documenteditor/mobile/src/controller/Error.jsx +++ b/apps/documenteditor/mobile/src/controller/Error.jsx @@ -259,6 +259,10 @@ const ErrorController = inject('storeAppOptions','storeDocumentInfo')(({storeApp config.msg = t('Error.errorPDFFormsLocked'); break; + case Asc.c_oAscError.ID.EditProtectedRange: + config.msg = t('Error.errorEditProtectedRange'); + break; + default: config.msg = _t.errorDefaultMessage.replace('%1', id); break;