[Lada-commits] [PATCH 5 of 6] Refactored messung edit window layout (LSB 3.8)

Wald Commits scm-commit at wald.intevation.org
Sat Dec 13 14:13:55 CET 2014


# HG changeset patch
# User Raimund Renkert <raimund.renkert at intevation.de>
# Date 1418476303 -3600
# Node ID ae8582b4f2074d92a4e09b85bc3cd3c566910176
# Parent  0c277c02eaef1794f196f4259c359cb20db79627
Refactored messung edit window layout (LSB 3.8).

diff -r 0c277c02eaef -r ae8582b4f207 app/view/messungen/Edit.js
--- a/app/view/messungen/Edit.js	Sat Dec 13 14:10:40 2014 +0100
+++ b/app/view/messungen/Edit.js	Sat Dec 13 14:11:43 2014 +0100
@@ -18,8 +18,7 @@
 
     title: 'Maske für Messungen',
     autoShow: true,
-    autoScroll: true,
-    modal: true,
+    layout: 'fit',
 
     initComponent: function() {
         var form = Ext.create('Lada.view.messungen.EditForm',
@@ -33,9 +32,13 @@
             scope: this,
             handler: this.close
         }];
-        this.width = Ext.getBody().getViewSize().width - 30;
-        this.height = Ext.getBody().getViewSize().height - 30;
-        this.items = [form];
+        this.width = 700;
+        this.maxHeight = Ext.getBody().getViewSize().height - 57;
+        this.items = [{
+            border: 0,
+            autoScroll: true,
+            items: [form]
+        }];
         this.callParent();
     }
 });
diff -r 0c277c02eaef -r ae8582b4f207 app/view/messungen/EditForm.js
--- a/app/view/messungen/EditForm.js	Sat Dec 13 14:10:40 2014 +0100
+++ b/app/view/messungen/EditForm.js	Sat Dec 13 14:11:43 2014 +0100
@@ -21,35 +21,53 @@
     ],
 
     model: 'Lada.model.Messung',
+    minWidth: 650,
 
     initComponent: function() {
         this.items = [{
-            xtype: 'textfield',
-            name: 'nebenprobenNr',
-            maxLength: 10,
-            fieldLabel: 'NPR'
-        }, {
-            xtype: 'messmethode',
-            name: 'mmtId',
-            fieldLabel: 'MMT'
-        }, {
-            xtype: 'datetime',
-            name: 'messzeitpunkt',
-            fieldLabel: 'Messzeitpunkt'
-        }, {
-            xtype: 'numberfield',
-            allowDecimals: false,
-            minValue: 0,
-            name: 'messdauer',
-            fieldLabel: 'Messdauer'
-        }, {
-            xtype: 'testdatensatz',
-            name: 'fertig',
-            fieldLabel: 'Fertig'
-        }, {
-            xtype: 'testdatensatz',
-            name: 'geplant',
-            fieldLabel: 'Geplant'
+            xtype: 'fieldset',
+            title: 'Allgemein',
+            items: [{
+                layout: {
+                    type: 'table',
+                    columns: 2
+                },
+                border: 0,
+                items: [{
+                    xtype: 'textfield',
+                    name: 'nebenprobenNr',
+                    maxLength: 10,
+                    margin: '0, 10, 5, 0',
+                    fieldLabel: 'Nebenprobennr.'
+                }, {
+                    xtype: 'messmethode',
+                    name: 'mmtId',
+                    margin: '0, 10, 5, 0',
+                    fieldLabel: 'Messmethode'
+                }, {
+                    xtype: 'datetime',
+                    name: 'messzeitpunkt',
+                    margin: '0, 10, 5, 0',
+                    fieldLabel: 'Messzeitpunkt'
+                }, {
+                    xtype: 'numberfield',
+                    allowDecimals: false,
+                    minValue: 0,
+                    name: 'messdauer',
+                    margin: '0, 10, 5, 0',
+                    fieldLabel: 'Messdauer'
+                }, {
+                    xtype: 'testdatensatz',
+                    name: 'fertig',
+                    margin: '0, 10, 5, 0',
+                    fieldLabel: 'Fertig'
+                }, {
+                    xtype: 'testdatensatz',
+                    name: 'geplant',
+                    margin: '0, 10, 5, 0',
+                    fieldLabel: 'Geplant'
+                }]
+            }]
         }, {
             // Messwerte
             xtype: 'fieldset',


More information about the Lada-commits mailing list