From a08d896d0add7f7ecb4efe72060be1ce45689e6e Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Tue, 7 Apr 2020 17:06:29 +0300 Subject: [PATCH] [SSE] Show info about removed duplicates --- .../spreadsheeteditor/main/app/controller/Main.js | 15 +++++++++++++-- apps/spreadsheeteditor/main/locale/en.json | 2 ++ 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/apps/spreadsheeteditor/main/app/controller/Main.js b/apps/spreadsheeteditor/main/app/controller/Main.js index d6c456e67..a8f300473 100644 --- a/apps/spreadsheeteditor/main/app/controller/Main.js +++ b/apps/spreadsheeteditor/main/app/controller/Main.js @@ -1477,6 +1477,15 @@ define([ config.msg = this.errorFTRangeIncludedOtherTables; break; + + case Asc.c_oAscError.ID.RemoveDuplicates: + config.iconCls = 'info'; + config.title = Common.UI.Window.prototype.textInformation; + config.buttons = ['ok']; + // config.msg = (errData.asc_getRemoved()>0) ? Common.Utils.String.format(this.errRemDuplicates, errData.asc_getRemoved(), errData.asc_getLeft()) : this.errNoDuplicates; + config.maxwidth = 600; + break; + default: config.msg = (typeof id == 'string') ? id : this.errorDefaultMessage.replace('%1', id); break; @@ -1525,7 +1534,7 @@ define([ if (id == Asc.c_oAscError.ID.EditingError || $('.asc-window.modal.alert:visible').length < 1 && (id !== Asc.c_oAscError.ID.ForceSaveTimeout)) { Common.UI.alert(config); - Common.component.Analytics.trackEvent('Internal Error', id.toString()); + (id!==undefined) && Common.component.Analytics.trackEvent('Internal Error', id.toString()); } }, @@ -2519,7 +2528,9 @@ define([ txtValues: 'Values', txtGrandTotal: 'Grand Total', txtRowLbls: 'Row Labels', - txtColLbls: 'Column Labels' + txtColLbls: 'Column Labels', + errNoDuplicates: 'No duplicate values found.', + errRemDuplicates: 'Duplicate values found and deleted: {0}, unique values left: {1}.' } })(), SSE.Controllers.Main || {})) }); diff --git a/apps/spreadsheeteditor/main/locale/en.json b/apps/spreadsheeteditor/main/locale/en.json index 0a13d9489..88fb1c218 100644 --- a/apps/spreadsheeteditor/main/locale/en.json +++ b/apps/spreadsheeteditor/main/locale/en.json @@ -811,6 +811,8 @@ "SSE.Controllers.Main.txtGrandTotal": "Grand Total", "SSE.Controllers.Main.txtRowLbls": "Row Labels", "SSE.Controllers.Main.txtColLbls": "Column Labels", + "SSE.Controllers.Main.errNoDuplicates": "No duplicate values found.", + "SSE.Controllers.Main.errRemDuplicates": "Duplicate values found and deleted: {0}, unique values left: {1}.", "SSE.Controllers.Print.strAllSheets": "All Sheets", "SSE.Controllers.Print.textWarning": "Warning", "SSE.Controllers.Print.txtCustom": "Custom",