[Lada-commits] [PATCH 2 of 2] Added missing file

Wald Commits scm-commit at wald.intevation.org
Thu Jul 4 12:22:50 CEST 2013


# HG changeset patch
# User Torsten Irländer <torsten.irlaender at intevation.de>
# Date 1372933311 -7200
# Node ID 133df8f75a12038810ed46a9766085d7489c3dd3
# Parent  f1f0351b6e2fca4652f7dbef7d1c372e814ee88c
Added missing file.

diff -r f1f0351b6e2f -r 133df8f75a12 app/view/Viewport.js
--- a/app/view/Viewport.js	Thu Jul 04 12:21:25 2013 +0200
+++ b/app/view/Viewport.js	Thu Jul 04 12:21:51 2013 +0200
@@ -9,19 +9,55 @@
 
     initComponent: function() {
         console.log('Setting up Viewport');
-        this.initSearch();
+        //this.initSearch();
 
         // Development related: 
         // Disable "initSearch" call and enable one of the following init
         // methods to get a dialog directly without the need to click through
         // the whole application.
-        //this.initMessung();
+        this.initMessung();
+        //this.initOrt();
 
         this.callParent(arguments);
     },
+    initMesswert: function() {
+        var store = Ext.getStore('Messwerte');
+        store.load({
+            params: {
+                probeId: "000007575853X",
+                messungsId: "1"
+            }
+        });
+    },
+    initOrt: function() {
+        var ort = Ext.create('Lada.model.Ort');
+        var win = Ext.create('Lada.view.orte.Create', {model: ort});
+    },
     initMessung: function() {
-        var messung = Ext.create('Lada.model.Messung');
-        var win = Ext.create('Lada.view.messungen.Create', {model: messung});
+        var store = Ext.getStore('Messungen');
+        var kstore = Ext.getStore('MKommentare');
+        probeId = "000007578314X";
+        store.load({
+            params: {
+                probeId: probeId
+            },
+            callback: function () {
+                console.log(store);
+                var messung = store.data.items[0];
+                console.log(store.data.items[0]);
+                kstore.load({
+                    params: {
+                        probeId: probeId,
+                        messungsId: messung.get('messungsId')
+                    },
+                    callback: function() {
+                        console.log('Creating Messung window');
+                        //var messung = Ext.create('Lada.model.Messung');
+                        var win = Ext.create('Lada.view.messungen.Create', {model: messung});
+                    }
+                });
+            }
+        });
     },
     initSearch: function() {
         this.items = {
diff -r f1f0351b6e2f -r 133df8f75a12 app/view/mkommentare/List.js
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/view/mkommentare/List.js	Thu Jul 04 12:21:51 2013 +0200
@@ -0,0 +1,6 @@
+Ext.define('Lada.view.mkommentare.List' ,{
+    extend: 'Lada.view.kommentare.List',
+    alias: 'widget.mkommentarelist',
+    store: 'MKommentare',
+    messungsId: null
+});


More information about the Lada-commits mailing list