From 46dc5a1e14f74409eff0b9af8da240f4222329d5 Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Thu, 12 Mar 2020 15:54:57 +0300 Subject: [PATCH] [SSE] Add translation for pivot tables --- .../main/app/controller/Main.js | 16 ++++++++++++++-- .../main/app/view/ValueFieldSettingsDialog.js | 4 ++-- apps/spreadsheeteditor/main/locale/en.json | 8 +++++++- apps/spreadsheeteditor/main/locale/ru.json | 3 ++- 4 files changed, 25 insertions(+), 6 deletions(-) diff --git a/apps/spreadsheeteditor/main/app/controller/Main.js b/apps/spreadsheeteditor/main/app/controller/Main.js index c3d48becd..785ed5d4e 100644 --- a/apps/spreadsheeteditor/main/app/controller/Main.js +++ b/apps/spreadsheeteditor/main/app/controller/Main.js @@ -121,7 +121,13 @@ define([ 'Tab': this.txtTab, 'File': this.txtFile, 'Column': this.txtColumn, - 'Row': this.txtRow + 'Row': this.txtRow, + '%1 of %2': this.txtByField, + '(All)': this.txtAll, + 'Values': this.txtValues, + 'Grand Total': this.txtGrandTotal, + 'Row Labels': this.txtRowLbls, + 'Column Labels': this.txtColLbls }; styleNames.forEach(function(item){ translate[item] = me['txtStyle_' + item.replace(/ /g, '_')] || item; @@ -2505,7 +2511,13 @@ define([ txtRow: 'Row', errorUpdateVersionOnDisconnect: 'Internet connection has been restored, and the file version has been changed.
Before you can continue working, you need to download the file or copy its content to make sure nothing is lost, and then reload this page.', errorFTChangeTableRangeError: 'Operation could not be completed for the selected cell range.
Select a range so that the first table row was on the same row
and the resulting table overlapped the current one.', - errorFTRangeIncludedOtherTables: 'Operation could not be completed for the selected cell range.
Select a range which does not include other tables.' + errorFTRangeIncludedOtherTables: 'Operation could not be completed for the selected cell range.
Select a range which does not include other tables.', + txtByField: '%1 of %2', + txtAll: '(All)', + txtValues: 'Values', + txtGrandTotal: 'Grand Total', + txtRowLbls: 'Row Labels', + txtColLbls: 'Column Labels' } })(), SSE.Controllers.Main || {})) }); diff --git a/apps/spreadsheeteditor/main/app/view/ValueFieldSettingsDialog.js b/apps/spreadsheeteditor/main/app/view/ValueFieldSettingsDialog.js index 440b78361..a1de6916f 100644 --- a/apps/spreadsheeteditor/main/app/view/ValueFieldSettingsDialog.js +++ b/apps/spreadsheeteditor/main/app/view/ValueFieldSettingsDialog.js @@ -253,7 +253,7 @@ define([ }, onSummarizeSelect: function(combo, record) { - this.inputCustomName.setValue(record.displayValue + ' ' + this.txtByField + ' ' + this.lblSourceName.text()); + this.inputCustomName.setValue(this.txtByField.replace('%1', record.displayValue).replace('%2', this.lblSourceName.text())); }, onShowAsSelect: function(combo, record) { @@ -295,7 +295,7 @@ define([ txtPercentOfCol: 'Percent of Column', txtPercentOfTotal: 'Percent of Row', txtIndex: 'Index', - txtByField: 'by field' + txtByField: '%1 of %2' }, SSE.Views.ValueFieldSettingsDialog || {})) }); \ No newline at end of file diff --git a/apps/spreadsheeteditor/main/locale/en.json b/apps/spreadsheeteditor/main/locale/en.json index 829a3eb85..41bcb1048 100644 --- a/apps/spreadsheeteditor/main/locale/en.json +++ b/apps/spreadsheeteditor/main/locale/en.json @@ -779,6 +779,12 @@ "SSE.Controllers.Main.warnNoLicense": "This version of %1 editors has certain limitations for concurrent connections to the document server.
If you need more please consider purchasing a commercial license.", "SSE.Controllers.Main.warnNoLicenseUsers": "This version of %1 editors has certain limitations for concurrent users.
If you need more please consider purchasing a commercial license.", "SSE.Controllers.Main.warnProcessRightsChange": "You have been denied the right to edit the file.", + "SSE.Controllers.Main.txtByField": "%1 of %2", + "SSE.Controllers.Main.txtAll": "(All)", + "SSE.Controllers.Main.txtValues": "Values", + "SSE.Controllers.Main.txtGrandTotal": "Grand Total", + "SSE.Controllers.Main.txtRowLbls": "Row Labels", + "SSE.Controllers.Main.txtColLbls": "Column Labels", "SSE.Controllers.Print.strAllSheets": "All Sheets", "SSE.Controllers.Print.textWarning": "Warning", "SSE.Controllers.Print.txtCustom": "Custom", @@ -2614,5 +2620,5 @@ "SSE.Views.ValueFieldSettingsDialog.txtPercentOfCol": "Percent of Column", "SSE.Views.ValueFieldSettingsDialog.txtPercentOfTotal": "Percent of Row", "SSE.Views.ValueFieldSettingsDialog.txtIndex": "Index", - "SSE.Views.ValueFieldSettingsDialog.txtByField": "by field" + "SSE.Views.ValueFieldSettingsDialog.txtByField": "%1 of %2" } \ No newline at end of file diff --git a/apps/spreadsheeteditor/main/locale/ru.json b/apps/spreadsheeteditor/main/locale/ru.json index 475515d23..96a221bf0 100644 --- a/apps/spreadsheeteditor/main/locale/ru.json +++ b/apps/spreadsheeteditor/main/locale/ru.json @@ -2496,5 +2496,6 @@ "SSE.Views.Top10FilterDialog.txtItems": "Элемент", "SSE.Views.Top10FilterDialog.txtPercent": "Процент", "SSE.Views.Top10FilterDialog.txtTitle": "Наложение условия по списку", - "SSE.Views.Top10FilterDialog.txtTop": "Наибольшие" + "SSE.Views.Top10FilterDialog.txtTop": "Наибольшие", + "SSE.Views.ValueFieldSettingsDialog.txtByField": "%1 по полю %2" } \ No newline at end of file