diff app/view/widgets/Datenbasis.js @ 121:c05fda928b82

Cleanup part two. Reenabled Proben edit but one use minimum version of the probenedit. Move some stores to the combobox definitons
author Torsten Irländer <torsten.irlaender@intevation.de>
date Fri, 21 Jun 2013 16:55:23 +0200
parents a1be7ccd4d0c
children 70a1b5962930
line wrap: on
line diff
--- a/app/view/widgets/Datenbasis.js	Fri Jun 21 16:53:39 2013 +0200
+++ b/app/view/widgets/Datenbasis.js	Fri Jun 21 16:55:23 2013 +0200
@@ -1,8 +1,22 @@
 // Combobox for Datenbasis
+var datenbasisStore = Ext.create('Ext.data.Store', {
+    fields: ['datenbasisId', 'beschreibung', 'datenbasis'],
+    proxy: {
+        type: 'ajax',
+        api: {
+        read: 'server/rest/datenbasis'
+        },
+        reader: {
+            type: 'json',
+            root: 'data'
+        }
+    }
+});
+
 Ext.define('Lada.view.widgets.Datenbasis' ,{
         extend: 'Ext.form.ComboBox',
         alias: 'widget.datenbasis',
-        store: 'Datenbasis',
+        store: datenbasisStore,
         displayField:'datenbasis',
         valueField: 'datenbasisId',
         emptyText:'Wählen Sie eine Datenbasis',
@@ -10,4 +24,3 @@
         this.callParent(arguments);
     }
 });
-

http://lada.wald.intevation.org