Skip to content

Commit e339662

Browse files
Correct localization for "No DrillThrough data"
1 parent 13c2aa7 commit e339662

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "LightPivotTable",
33
"author": "ZitRo",
4-
"version": "1.4.5",
4+
"version": "1.4.6",
55
"description": "A lightweight pivot table for MDX2JSON source for InterSystems Cache",
66
"main": "test/testServer.js",
77
"repository": {

source/js/DataSource.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ DataSource.prototype.getCurrentData = function (callback) {
186186
obj, i, u;
187187

188188
if (!arr.length) return {
189-
error: "No DrillThrough data."
189+
error: pivotLocale.get(4)
190190
};
191191

192192
for (i in arr[0]) {

source/js/PivotLocale.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,11 @@ PivotLocale.prototype.LOCALES = [
3838
"ru": "Возникла ошибка при получении данных с сервера.",
3939
"en": "Error while trying to retrieve data from server.",
4040
"de": "Beim Abrufen der Daten vom Server ist ein Fehler aufgetreten."
41+
},
42+
{ // 4
43+
"ru": "Нет данных для отображения.",
44+
"en": "No data to display.",
45+
"de": "Keine Daten zum anzeigen."
4146
}
4247
];
4348

@@ -71,7 +76,7 @@ PivotLocale.prototype.setLocale = function (locale) {
7176
*/
7277
PivotLocale.prototype.get = function (index) {
7378

74-
return (this.LOCALES[index] || {})[this.LOCALE] || "{not localized}";
79+
return (this.LOCALES[index] || {})[this.LOCALE] || ("{not localized: " + index + "}");
7580

7681
};
7782

0 commit comments

Comments
 (0)