annotate app/view/Viewport.js @ 488:f7446ebfe5d0

Added and updated models.
author Raimund Renkert <raimund.renkert@intevation.de>
date Fri, 31 Oct 2014 21:10:35 +0100
parents debfcc7713e3
children 446e99cfd425
rev   line source
472
debfcc7713e3 Added license header to each file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 426
diff changeset
1 /* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
debfcc7713e3 Added license header to each file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 426
diff changeset
2 * Software engineering by Intevation GmbH
debfcc7713e3 Added license header to each file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 426
diff changeset
3 *
debfcc7713e3 Added license header to each file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 426
diff changeset
4 * This file is Free Software under the GNU GPL (v>=3)
debfcc7713e3 Added license header to each file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 426
diff changeset
5 * and comes with ABSOLUTELY NO WARRANTY! Check out
debfcc7713e3 Added license header to each file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 426
diff changeset
6 * the documentation coming with IMIS-Labordaten-Application for details.
debfcc7713e3 Added license header to each file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 426
diff changeset
7 */
debfcc7713e3 Added license header to each file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 426
diff changeset
8
341
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
9 /**
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
10 * Viewport for the Lada-Client
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
11 *
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
12 * The viewport initialises the graphical elements of the application. For
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
13 * debugging it is possible to initialize other components directly see the
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
14 * initComponent function.
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
15 */
12
cdcaf38eab45 Added Viewport class which should be used to setup the viewport. Currently not
Torsten Irländer <torsten.irlaender@intevation.de>
parents:
diff changeset
16 Ext.define('Lada.view.Viewport' ,{
cdcaf38eab45 Added Viewport class which should be used to setup the viewport. Currently not
Torsten Irländer <torsten.irlaender@intevation.de>
parents:
diff changeset
17 extend: 'Ext.container.Viewport',
cdcaf38eab45 Added Viewport class which should be used to setup the viewport. Currently not
Torsten Irländer <torsten.irlaender@intevation.de>
parents:
diff changeset
18 requires: [
259
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
19 'Lada.store.Info',
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
20 'Lada.view.search.List',
369
cebed9ef8293 Dynamically add configured search filters. Send needed values to the server.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 357
diff changeset
21 'Lada.view.proben.List'
12
cdcaf38eab45 Added Viewport class which should be used to setup the viewport. Currently not
Torsten Irländer <torsten.irlaender@intevation.de>
parents:
diff changeset
22 ],
425
2ff236e5d2d0 Added layout to the Viewport (root panel) to fix some layout issues.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 412
diff changeset
23 layout: 'fit',
12
cdcaf38eab45 Added Viewport class which should be used to setup the viewport. Currently not
Torsten Irländer <torsten.irlaender@intevation.de>
parents:
diff changeset
24 initComponent: function() {
cdcaf38eab45 Added Viewport class which should be used to setup the viewport. Currently not
Torsten Irländer <torsten.irlaender@intevation.de>
parents:
diff changeset
25 console.log('Setting up Viewport');
357
94884cd8f8c0 Added logic to upload a file to the server.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 355
diff changeset
26 this.initSearch();
173
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
27
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
28 // Development related:
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
29 // Disable "initSearch" call and enable one of the following init
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
30 // methods to get a dialog directly without the need to click through
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
31 // the whole application.
230
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
32 //this.initProbe();
180
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
33 //this.initOrt();
184
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
34 //this.initMessung();
357
94884cd8f8c0 Added logic to upload a file to the server.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 355
diff changeset
35 //this.initMesswert();
173
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
36
357
94884cd8f8c0 Added logic to upload a file to the server.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 355
diff changeset
37 this.setInfo();
173
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
38 this.callParent(arguments);
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
39 },
341
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
40 /**
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
41 * Set some information about user, client and server version in the top
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
42 * of the application window. The data will be fetched from the server.
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
43 */
259
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
44 setInfo: function() {
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
45 var store = Ext.create('Lada.store.Info');
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
46 store.load({
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
47 callback: function(a,b,c) {
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
48 var info = store.data.items[0];
262
1626279daadb Set client version
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 259
diff changeset
49 var clientVersion = "r261 (2013-07-26)";
259
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
50 var user = info.get('user');
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
51 var groups = info.get('groups');
383
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
52 var groupinfo = Ext.getCmp('groupinfo');
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
53 var userinfo = Ext.getCmp('userinfo');
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
54 userinfo.update(user);
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
55 groupinfo.update(groups);
259
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
56 console.log(info);
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
57 }
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
58 });
d19ad9d28de5 Added code to show general information about the application in the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 250
diff changeset
59 },
341
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
60 /**
412
cf4b6e93f956 Typo fixed.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 393
diff changeset
61 * Function to initialize the edit window for a particular probe directly
341
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
62 * @private
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
63 */
230
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
64 initProbe: function() {
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
65 var store = Ext.getStore('Proben');
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
66 store.load({
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
67 params: {
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
68 probeId: "000007575943X"
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
69 },
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
70 callback: function() {
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
71 var mstore = Ext.getStore('Messungen');
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
72 mstore.load({
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
73 params: {
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
74 probeId: "000007575943X"
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
75 }
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
76 });
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
77 var model = store.data.items[0];
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
78 var win = Ext.create('Lada.view.proben.Edit', {model: model});
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
79 }
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
80 });
7bea6974fb5b Added function to directly initialize the probenendit form.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 214
diff changeset
81 },
341
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
82 /**
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
83 * Function to initialize the edit window for a priticular messwert directly
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
84 * @private
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
85 */
180
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
86 initMesswert: function() {
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
87 var store = Ext.getStore('Messwerte');
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
88 store.load({
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
89 params: {
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
90 probeId: "000007575853X",
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
91 messungsId: "1"
184
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
92 },
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
93 callback: function() {
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
94 var model = store.data.items[0];
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
95 var win = Ext.create('Lada.view.messwerte.Create', {model: model});
180
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
96 }
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
97 });
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
98 },
341
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
99 /**
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
100 * Function to initialize the edit window for a priticular ort directly
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
101 * @private
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
102 */
180
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
103 initOrt: function() {
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
104 var ort = Ext.create('Lada.model.Ort');
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
105 var win = Ext.create('Lada.view.orte.Create', {model: ort});
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
106 },
341
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
107 /**
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
108 * Function to initialize the edit window for a priticular ort directly
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
109 * @private
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
110 */
173
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
111 initMessung: function() {
180
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
112 var store = Ext.getStore('Messungen');
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
113 var kstore = Ext.getStore('MKommentare');
184
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
114 var mstore = Ext.getStore('Messwerte');
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
115 var sstore = Ext.getStore('Status');
180
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
116 probeId = "000007578314X";
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
117 store.load({
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
118 params: {
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
119 probeId: probeId
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
120 },
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
121 callback: function () {
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
122 console.log(store);
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
123 var messung = store.data.items[0];
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
124 console.log(store.data.items[0]);
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
125 kstore.load({
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
126 params: {
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
127 probeId: probeId,
214
38e84783785f Fix getting messerte, status and kommentare in debug mode
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 184
diff changeset
128 messungsId: messung.get('id').messungsId
180
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
129 }
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
130 });
184
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
131 sstore.load({
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
132 params: {
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
133 probeId: probeId,
214
38e84783785f Fix getting messerte, status and kommentare in debug mode
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 184
diff changeset
134 messungsId: messung.get('id').messungsId
184
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
135 }
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
136 });
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
137 mstore.load({
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
138 params: {
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
139 probeId: probeId,
214
38e84783785f Fix getting messerte, status and kommentare in debug mode
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 184
diff changeset
140 messungsId: messung.get('id').messungsId
184
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
141 }
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
142 });
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
143 console.log('Creating Messung window');
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
144 //var messung = Ext.create('Lada.model.Messung');
cfa4ed3b62b5 Show search on app startup.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 180
diff changeset
145 var win = Ext.create('Lada.view.messungen.Create', {model: messung});
180
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
146 }
133df8f75a12 Added missing file.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 173
diff changeset
147 });
173
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
148 },
341
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
149 /**
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
150 * Function to initialize the search window. This is the default method
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
151 * called by the {@link Lada.view.Viewport#initComponent initComponent} method.
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
152 * @private
6eaa741b396b Added documentation.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 262
diff changeset
153 */
173
1a11ae666f11 Added options to open dialogs directly without the need to click through the
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 148
diff changeset
154 initSearch: function() {
383
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
155 this.items = [{
25
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
156 xtype: 'panel',
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
157 title: '<center>Probenauswahlmaske</center>',
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
158 bodyPadding: '10 10',
425
2ff236e5d2d0 Added layout to the Viewport (root panel) to fix some layout issues.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 412
diff changeset
159 layout: {
2ff236e5d2d0 Added layout to the Viewport (root panel) to fix some layout issues.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 412
diff changeset
160 type: 'vbox',
2ff236e5d2d0 Added layout to the Viewport (root panel) to fix some layout issues.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 412
diff changeset
161 align: 'stretch'
2ff236e5d2d0 Added layout to the Viewport (root panel) to fix some layout issues.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 412
diff changeset
162 },
383
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
163 dockedItems: [
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
164 {
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
165 xtype: "toolbar",
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
166 dock: "top",
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
167 items: [{
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
168 xtype: "splitbutton",
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
169 text: "Info",
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
170 menu: {
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
171 items: [{
386
00bf2d4f3bd1 Added about dialog.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 384
diff changeset
172 id: 'AboutBtn',
383
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
173 text: "About"
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
174 }]
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
175 }
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
176 },
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
177 "->",
391
d1bb925bb5f5 Use the new icons in list views and status bar.
Raimund Renkert <rrenkert@intevation.de>
parents: 384
diff changeset
178 {xtype: 'box', autoEl: {tag: 'img', src:'gfx/user-identity.png'}},
384
ea424aacd07f Added user icons to the toolbar.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 383
diff changeset
179 {xtype: "tbtext", id:"userinfo", text:""},
391
d1bb925bb5f5 Use the new icons in list views and status bar.
Raimund Renkert <rrenkert@intevation.de>
parents: 384
diff changeset
180 {xtype: 'box', autoEl: {tag: 'img', src:'gfx/network-workgroup.png'}},
384
ea424aacd07f Added user icons to the toolbar.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 383
diff changeset
181 {xtype: "tbtext", id:"groupinfo", text:""}
383
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
182 ]
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
183 }
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
184 ],
25
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
185 items: [
31
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
186 // Auswahl einer Abfrage.
25
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
187 {
28
4d60b9ebce15 Renamed sql modul into search. Further display The query selection as Combobox
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 25
diff changeset
188 xtype: 'queryselector',
369
cebed9ef8293 Dynamically add configured search filters. Send needed values to the server.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 357
diff changeset
189 id: 'queryselector',
25
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
190 margin: '0 0 10 0'
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
191 },
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
192 // Variables settings for the current selected sql statement.
31
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
193 {
245
9a2c04b19874 Put all available search filters to the viewport. They are later hidden and
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 230
diff changeset
194 xtype: 'fieldset',
9a2c04b19874 Put all available search filters to the viewport. They are later hidden and
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 230
diff changeset
195 id: 'queryfilters',
9a2c04b19874 Put all available search filters to the viewport. They are later hidden and
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 230
diff changeset
196 title: 'Variablenbelegung',
9a2c04b19874 Put all available search filters to the viewport. They are later hidden and
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 230
diff changeset
197 hidden: true,
369
cebed9ef8293 Dynamically add configured search filters. Send needed values to the server.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 357
diff changeset
198 items: []
31
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
199 },
120
19eab475bbe5 Clean up part one. Reduced application to the search page. Moved some stores for comoboboxes right to the combobox
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 39
diff changeset
200 // Buttons to trigger the search.
31
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
201 {
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
202 id: 'SearchBtnPanel',
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
203 xtype: 'panel',
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
204 border: false,
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
205 margin: '0 0 10 0',
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
206 items: [
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
207 {
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
208 id: 'SearchBtn',
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
209 text: 'Suchen',
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
210 xtype: 'button',
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
211 margin: '0 10 0 0'
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
212 },
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
213 {
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
214 id: 'ResetBtn',
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
215 text: 'Zurücksetzen',
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
216 xtype: 'button'
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
217 }
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
218 ],
148
ed7fb4fa32dc Do not hide search buttons and the resultlist on initial load.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 120
diff changeset
219 hidden: false
31
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
220
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
221 },
25
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
222 // Resultlist for the query.
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
223 {
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
224 id: 'result',
426
c95c9831675c Set flex to true for the probenlist. Remove minheigt and maxheigt from panel
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 425
diff changeset
225 flex: 1,
31
897e3100c6da Changed logic of the Probenauswahl. Now logic works like the BFS version.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 28
diff changeset
226 xtype: 'probenlist',
148
ed7fb4fa32dc Do not hide search buttons and the resultlist on initial load.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 120
diff changeset
227 hidden: false
25
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
228 }
f964a50bfe57 Restructured the application. Fixed layouts etc.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 12
diff changeset
229 ]
383
fe8d6e1b08ff Added toolbar to the mainwindow.
Torsten Irländer <torsten.irlaender@intevation.de>
parents: 369
diff changeset
230 }];
12
cdcaf38eab45 Added Viewport class which should be used to setup the viewport. Currently not
Torsten Irländer <torsten.irlaender@intevation.de>
parents:
diff changeset
231 }
cdcaf38eab45 Added Viewport class which should be used to setup the viewport. Currently not
Torsten Irländer <torsten.irlaender@intevation.de>
parents:
diff changeset
232 });

http://lada.wald.intevation.org