diff app/view/window/Ortserstellung.js @ 1284:faecbb446a04

Ortserstellung: new Messpunkt from map, clone or form functional, still needs error handling and layout
author Maximilian Krambach <mkrambach@intevation.de>
date Tue, 24 Jan 2017 12:58:26 +0100
parents
children bfdc00c24baf
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/view/window/Ortserstellung.js	Tue Jan 24 12:58:26 2017 +0100
@@ -0,0 +1,54 @@
+/* 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.
+ */
+
+/**
+ * Window for new Ort, wraps around a {@link Lada.view.form.Ortsertellung}
+ */
+Ext.define('Lada.view.window.Ortserstellung', {
+    extend: 'Ext.window.Window',
+    alias: 'window.ortserstellung',
+    requires: [
+        'Lada.model.Ort',
+        'Lada.view.form.Ortserstellung'
+    ],
+
+    minWidth: 350,
+
+    margin: 5,
+
+    border: 0,
+
+    bodyStyle: {background: '#fff'},
+
+    layout: 'fit',
+
+    title: 'Neuen Messpunkt anlegen',
+
+    /**
+     * The record for the new Ort. Should be a {@link Lada.model.Ort}
+     */
+    record: null,
+
+    parentWindow: null,
+
+    initComponent: function() {
+        var me = this;
+        if (this.record === null) {
+            this.record = Ext.create('Lada.model.Ort');
+        }
+        this.items = [
+            Ext.create('Lada.view.form.Ortserstellung', {
+                record: me.record,
+                listeners: {
+                    destroy: {fn: function() {me.close();}}
+                }
+            })
+        ];
+        this.callParent(arguments);
+    }
+});
\ No newline at end of file

http://lada.wald.intevation.org