changeset 679:60a3e9809ea4

moved code from translations_de.js into proper overrides
author Dustin Demuth <dustin@intevation.de>
date Tue, 24 Mar 2015 12:07:35 +0100
parents 0d5fb0f585f1
children 31fc4f94f98f
files app.js app/override/JSON.js app/override/i18n/DE.js app/override/i18n/de/RowEditor.js app/override/i18n/de/picker/Date.js app/override/i18n/de/toolbar/Paging.js index.html resources/lib/translations_de.js
diffstat 8 files changed, 103 insertions(+), 65 deletions(-) [+]
line wrap: on
line diff
--- a/app.js	Mon Mar 23 18:04:59 2015 +0100
+++ b/app.js	Tue Mar 24 12:07:35 2015 +0100
@@ -25,6 +25,8 @@
         'Lada.override.Table',
         'Lada.override.RestProxy',
         'Lada.override.RowEditor',
+        'Lada.override.i18n.DE',
+        'Lada.override.JSON',
         'Ext.i18n.Bundle',
         'Ext.layout.container.Column',
         'Lada.store.Datenbasis',
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/override/JSON.js	Tue Mar 24 12:07:35 2015 +0100
@@ -0,0 +1,18 @@
+/* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU GPL (v>=3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out
+ * the documentation coming with IMIS-Labordaten-Application for details.
+ */
+
+
+// The Date returned by EXT-JSON serializer has to contain the timezone identifier
+
+Ext.define("Lada.override.JSON", {
+    override: 'Ext.JSON',
+    encodeDate: function(o){
+        return '"' + Ext.Date.format(o, 'c') + '"';
+    }
+});
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/override/i18n/DE.js	Tue Mar 24 12:07:35 2015 +0100
@@ -0,0 +1,19 @@
+/* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU GPL (v>=3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out
+ * the documentation coming with IMIS-Labordaten-Application for details.
+ */
+
+
+// Require all Libraries from de/ 
+
+Ext.define("Lada.override.i18n.DE", {
+    requires:[
+       'Lada.override.i18n.de.toolbar.Paging',
+       'Lada.override.i18n.de.picker.Date',
+       'Lada.override.i18n.de.RowEditor'
+    ]
+});
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/override/i18n/de/RowEditor.js	Tue Mar 24 12:07:35 2015 +0100
@@ -0,0 +1,17 @@
+/* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU GPL (v>=3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out
+ * the documentation coming with IMIS-Labordaten-Application for details.
+ */
+
+// This file adds or corrects translations.
+
+Ext.define('Lada.override.i18n.de.RowEditor', {
+    override: 'Ext.grid.RowEditor',
+    saveBtnText:  'Speichern',
+    cancelBtnText: 'Abbrechen',
+    errorsText: 'Fehler',
+    dirtyText: 'Sie müssen Ihre Änderungen Speichern oder durch Abbrechen verwerfen'
+});
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/override/i18n/de/picker/Date.js	Tue Mar 24 12:07:35 2015 +0100
@@ -0,0 +1,25 @@
+/* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU GPL (v>=3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out
+ * the documentation coming with IMIS-Labordaten-Application for details.
+ */
+
+// This file adds or corrects translations.
+
+Ext.define("Lada.override.i18n.de.picker.Date", {
+    override: "Ext.picker.Date",
+    todayText: "Heute",
+    minText: "Dieses Datum liegt vor dem erstmöglichen Datum", // von -> vor
+    maxText: "Dieses Datum liegt nach dem letztmöglichen Datum",
+    disabledDaysText: "",
+    disabledDatesText: "",
+    nextText: "Nächster Monat (Strg/Control + Rechts)",
+    prevText: "Vorheriger Monat (Strg/Control + Links)",
+    monthYearText: "Monat auswählen (Strg/Control + Hoch/Runter, um ein Jahr auszuwählen)",
+    todayTip: "Heute ({0}) (Leertaste)",
+    format: "d.m.Y",
+    startDay: 1
+});
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/override/i18n/de/toolbar/Paging.js	Tue Mar 24 12:07:35 2015 +0100
@@ -0,0 +1,22 @@
+/* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU GPL (v>=3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out
+ * the documentation coming with IMIS-Labordaten-Application for details.
+ */
+
+// This file adds or corrects translations.
+
+Ext.define("Lada.override.i18n.de.toolbar.Paging", {
+    override: "Ext.toolbar.Paging",
+    beforePageText: "Seite",
+    afterPageText: "von {0}",
+    firstText: "Erste Seite",
+    prevText: "vorherige Seite",
+    nextText: "nächste Seite",
+    lastText: "letzte Seite",
+    refreshText: "Aktualisieren",
+    displayMsg: "Zeige Eintrag {0} - {1} von {2}", // Anzeige -> Zeige
+    emptyMsg: "Keine Daten vorhanden"
+});
--- a/index.html	Mon Mar 23 18:04:59 2015 +0100
+++ b/index.html	Tue Mar 24 12:07:35 2015 +0100
@@ -21,7 +21,6 @@
     <script type="text/javascript" src="extjs/ext-all-debug.js"></script>
     <script type="text/javascript" src="extjs/locale/ext-lang-de.js"></script>
     <!-- </x-bootstrap> -->
-    <script type="text/javascript" src="resources/lib/translations_de.js"></script>
     <script type="text/javascript" src="app.js"></script>
     <!-- </x-compile> -->
 </head>
--- a/resources/lib/translations_de.js	Mon Mar 23 18:04:59 2015 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,64 +0,0 @@
-/* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
- * Software engineering by Intevation GmbH
- *
- * This file is Free Software under the GNU GPL (v>=3)
- * and comes with ABSOLUTELY NO WARRANTY! Check out
- * the documentation coming with IMIS-Labordaten-Application for details.
- */
-
-/*
- * More Translations for extJS.
- * Not everything is covered in the original translation.
- * This file can be used to extend it.
- */
-
-Ext.onReady(function() {
-    if (Ext.grid.RowEditor) {
-        Ext.grid.RowEditor.prototype.saveBtnText = "Speichern";
-        Ext.grid.RowEditor.prototype.cancelBtnText = "Abbrechen";
-        Ext.grid.RowEditor.prototype.errorsText = "Fehler";
-        Ext.grid.RowEditor.prototype.dirtyText = "Sie müssen Ihre Änderungen Speichern oder durch Abbrechen verwerfen";
-    }
-
-// Ext has to send timezone-information when saving date-objects
-// If not: Datetime-information will be falsified when a date-object is saved
-// i.e
-// originaltime 8:00 (save) -> time+offset 9:00 (save) -> 10:00 -> etc...
-Ext.JSON.encodeDate = function(o)
-{
-    return '"' + Ext.Date.format(o, 'c') + '"';
-}
-
-
-});
-
-
-//Übersetzungsfehler
-Ext.define("Ext.locale.de.toolbar.Paging", {
-    override: "Ext.PagingToolbar",
-    beforePageText: "Seite",
-    afterPageText: "von {0}",
-    firstText: "Erste Seite",
-    prevText: "vorherige Seite",
-    nextText: "nächste Seite",
-    lastText: "letzte Seite",
-    refreshText: "Aktualisieren",
-    displayMsg: "Zeige Eintrag {0} - {1} von {2}", // Anzeige -> Zeige
-    emptyMsg: "Keine Daten vorhanden"
-});
-
-Ext.define("Ext.locale.de.picker.Date", {
-    override: "Ext.picker.Date",
-    todayText: "Heute",
-    minText: "Dieses Datum liegt vor dem erstmöglichen Datum", // von -> vor
-    maxText: "Dieses Datum liegt nach dem letztmöglichen Datum",
-    disabledDaysText: "",
-    disabledDatesText: "",
-    nextText: "Nächster Monat (Strg/Control + Rechts)",
-    prevText: "Vorheriger Monat (Strg/Control + Links)",
-    monthYearText: "Monat auswählen (Strg/Control + Hoch/Runter, um ein Jahr auszuwählen)",
-    todayTip: "Heute ({0}) (Leertaste)",
-    format: "d.m.Y",
-    startDay: 1
-});
-

http://lada.wald.intevation.org