From 25ef0ea5bbda7eb464d8453570f4f7a73e92ef1c Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Thu, 3 Oct 2019 16:39:48 +0300 Subject: [PATCH] [SSE] Fix Bug 43053 --- .../main/app/view/FormatSettingsDialog.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/apps/spreadsheeteditor/main/app/view/FormatSettingsDialog.js b/apps/spreadsheeteditor/main/app/view/FormatSettingsDialog.js index aed3bc881..4d68defda 100644 --- a/apps/spreadsheeteditor/main/app/view/FormatSettingsDialog.js +++ b/apps/spreadsheeteditor/main/app/view/FormatSettingsDialog.js @@ -424,13 +424,19 @@ define([ if (hasNegative || record.value == Asc.c_oAscNumFormatType.Date || record.value == Asc.c_oAscNumFormatType.Time) { if (hasSymbols) { if (!me.CurrencySymbolsData) { - me.CurrencySymbolsData = [{value: null, displayValue: me.txtNone}]; + me.CurrencySymbolsData = []; var symbolssarr = this.api.asc_getCurrencySymbols(); for (var code in symbolssarr) { if (symbolssarr.hasOwnProperty(code)) { me.CurrencySymbolsData.push({value: parseInt(code), displayValue: symbolssarr[code] + ' ' + Common.util.LanguageInfo.getLocalLanguageName(code)[1]}); } } + me.CurrencySymbolsData.sort(function(a, b){ + if (a.displayValue < b.displayValue) return -1; + if (a.displayValue > b.displayValue) return 1; + return 0; + }); + me.CurrencySymbolsData.unshift({value: null, displayValue: me.txtNone}); this.cmbSymbols.setData(this.CurrencySymbolsData); this.cmbSymbols.setValue(valSymbol); }