annotate app/view/Viewport.js @ 740:2e8da590ea0c

made Comboboces editable and filterable for; Messungenform: Messstelle,Datenbasis,Betriebsarts,Testdatensatz,Preobenart,Netzbetreiber Messungform: Messmethode Messwertegrid: Messgroesse,Messeinheit
author Dustin Demuth <dustin@intevation.de>
date Mon, 20 Apr 2015 16:07:40 +0200
parents b400629a2575
children 3ffecbce17d6
rev   line source
548
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
1 /* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
2 * Software engineering by Intevation GmbH
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
3 *
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
4 * This file is Free Software under the GNU GPL (v>=3)
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
5 * and comes with ABSOLUTELY NO WARRANTY! Check out
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
6 * the documentation coming with IMIS-Labordaten-Application for details.
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
7 */
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
8
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
9 /**
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
10 * Viewport for the Lada-Client
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
11 *
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
12 * The viewport initialises the graphical elements of the application. For
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
13 * debugging it is possible to initialize other components directly see the
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
14 * initComponent function.
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
15 */
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
16 Ext.define('Lada.view.Viewport', {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
17 extend: 'Ext.container.Viewport',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
18 requires: [
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
19 'Lada.view.FilterPanel',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
20 'Lada.view.grid.FilterResult'
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
21 ],
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
22 layout: 'fit',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
23 initComponent: function() {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
24 this.items = [{
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
25 title: '<center>Labordatenerfassung</center>',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
26 layout: 'border',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
27 name: 'main',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
28 items: [{
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
29 layout: {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
30 type: 'vbox',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
31 align: 'stretch'
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
32 },
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
33 region: 'west',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
34 split: true,
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
35 border: 1,
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
36 flex: 1,
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
37 dockedItems: [{
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
38 xtype: 'toolbar',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
39 dock: 'top',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
40 items: [{
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
41 xtype: 'splitbutton',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
42 text: 'Info',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
43 menu: {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
44 items: [{
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
45 text: 'About',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
46 action: 'about'
693
817524db4017 Readonly was missing
Dustin Demuth <dustin@intevation.de>
parents: 548
diff changeset
47 }, {
716
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
48 text: 'Anmeldeinformationen',
693
817524db4017 Readonly was missing
Dustin Demuth <dustin@intevation.de>
parents: 548
diff changeset
49 handler: function(){
716
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
50 logintime = new Date(Lada.logintime);
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
51 Ext.Msg.alert("Anmeldeinformationen",
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
52 "<p>"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
53 + "Sie sind angemeldet mit der Kennung:"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
54 + "<br />"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
55 + Lada.username
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
56 + "</p>"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
57 + "<p>"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
58 + "Sie sind Mitglied der folgenden "
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
59 + "Gruppen:"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
60 + "<br />"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
61 + Lada.userroles
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
62 + "</p>"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
63 + "<p>"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
64 + "<br/>"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
65 + "Die Anmeldung wurde durchgeführt um:"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
66 + "<br />"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
67 + Ext.Date.format(logintime, 'd.m.Y H:i:s P')
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
68 + "</p>"
b400629a2575 Added Logininformation to a Popup in Viewport
Dustin Demuth <dustin@intevation.de>
parents: 693
diff changeset
69 );
693
817524db4017 Readonly was missing
Dustin Demuth <dustin@intevation.de>
parents: 548
diff changeset
70 }
817524db4017 Readonly was missing
Dustin Demuth <dustin@intevation.de>
parents: 548
diff changeset
71 }
817524db4017 Readonly was missing
Dustin Demuth <dustin@intevation.de>
parents: 548
diff changeset
72 ]
548
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
73 }
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
74 }, '->', {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
75 xtype: 'box',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
76 autoEl: {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
77 tag: 'img',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
78 src: 'resources/img/user-identity.png'
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
79 }
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
80 }, {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
81 xtype: 'tbtext',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
82 id: 'userinfo',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
83 text: ''
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
84 }, {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
85 xtype: 'box',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
86 autoEl: {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
87 tag: 'img',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
88 src: 'resources/img/network-workgroup.png'
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
89 }
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
90 }, {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
91 xtype: 'tbtext',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
92 id: 'groupinfo',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
93 text: ''
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
94 }]
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
95 }],
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
96 items: [{
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
97 // Auswahl einer Abfrage.
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
98 xtype: 'filterpanel',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
99 margin: '0, 10, 0, 10'
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
100 }, {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
101 // Variables settings for the current selected sql statement.
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
102 xtype: 'fieldset',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
103 name: 'filtervariables',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
104 title: 'Variablenbelegung',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
105 hidden: true,
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
106 margin: '0, 10, 0, 10',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
107 items: []
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
108 }]
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
109 }, {
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
110 // Resultlist for the query.
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
111 flex: 3,
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
112 xtype: 'filterresultgrid',
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
113 hidden: false,
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
114 region: 'center'
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
115 }]
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
116 }];
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
117 this.callParent(arguments);
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
118 }
d47ee7439f44 Added new js files.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
diff changeset
119 });

http://lada.wald.intevation.org