Mercurial > lada > lada-client
annotate app/view/form/Messprogramm.js @ 1411:e749d09fafca release-2.5
show MPR-ID in form/Messgrogramm
author | Evi Huber <ehuber@bfs.de> |
---|---|
date | Mon, 27 Mar 2017 09:56:17 +0200 |
parents | 418b9afee700 |
children | 01f083db45b7 |
rev | line source |
---|---|
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
1 /* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
2 * Software engineering by Intevation GmbH |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
3 * |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
4 * This file is Free Software under the GNU GPL (v>=3) |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
5 * and comes with ABSOLUTELY NO WARRANTY! Check out |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
6 * the documentation coming with IMIS-Labordaten-Application for details. |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
7 */ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
8 |
894 | 9 /** |
10 * Form to edit a Messprogramm | |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
11 */ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
12 Ext.define('Lada.view.form.Messprogramm', { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
13 extend: 'Ext.form.Panel', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
14 alias: 'widget.messprogrammform', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
15 requires: [ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
16 'Lada.view.widget.Datenbasis', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
17 'Lada.view.widget.base.CheckBox', |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
18 'Lada.view.widget.Messstelle', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
19 'Lada.view.widget.Netzbetreiber', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
20 'Lada.view.widget.Betriebsart', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
21 'Lada.view.widget.Probenart', |
1258 | 22 'Lada.view.widget.MessprogrammLand', |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
23 'Lada.view.widget.Umwelt', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
24 'Lada.view.widget.base.TextField', |
1168
40a07eb873bf
Add numberfield with error/warning functionality and use for Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1167
diff
changeset
|
25 'Lada.view.widget.base.NumberField', |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
26 'Lada.view.widget.base.FieldSet', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
27 'Lada.model.Messprogramm', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
28 'Lada.model.MmtMessprogramm', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
29 'Lada.view.widget.Probenintervall', |
797
b8fd43021c29
Added a Window to alter Orte of a Messprogramm
Dustin Demuth <dustin@intevation.de>
parents:
793
diff
changeset
|
30 'Lada.view.widget.Location', |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
31 'Lada.view.widget.ProbenintervallSlider', |
1199
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
32 'Lada.view.widget.DayOfYear' |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
33 ], |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
34 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
35 model: 'Lada.model.Messprogramm', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
36 minWidth: 650, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
37 margin: 5, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
38 border: 0, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
39 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
40 recordId: null, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
41 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
42 trackResetOnLoad: true, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
43 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
44 initComponent: function() { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
45 var me = this; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
46 var i18n = Lada.getApplication().bundle; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
47 this.items = [{ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
48 xtype: 'fieldset', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
49 title: i18n.getMsg('messprogramm.form.fieldset.title'), |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
50 items: [{ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
51 border: 0, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
52 margin: '0, 0, 10, 0', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
53 dockedItems: [{ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
54 xtype: 'toolbar', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
55 dock: 'bottom', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
56 border: '0, 1, 1, 1', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
57 style: { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
58 borderBottom: '1px solid #b5b8c8 !important', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
59 borderLeft: '1px solid #b5b8c8 !important', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
60 borderRight: '1px solid #b5b8c8 !important' |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
61 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
62 items: ['->', { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
63 text: i18n.getMsg('save'), |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
64 qtip: i18n.getMsg('save.qtip'), |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
65 icon: 'resources/img/dialog-ok-apply.png', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
66 action: 'save', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
67 disabled: true |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
68 }, { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
69 text: i18n.getMsg('discard'), |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
70 qtip: i18n.getMsg('discard.qtip'), |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
71 icon: 'resources/img/dialog-cancel.png', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
72 action: 'discard', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
73 disabled: true |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
74 }] |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
75 }], |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
76 items: [{ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
77 border: 0, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
78 minWidth: 290, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
79 layout: { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
80 type: 'vbox', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
81 align: 'stretch' |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
82 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
83 margin: '0, 10, 0, 0', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
84 items: [{ |
1411
e749d09fafca
show MPR-ID in form/Messgrogramm
Evi Huber <ehuber@bfs.de>
parents:
1396
diff
changeset
|
85 xtype: 'displayfield', |
e749d09fafca
show MPR-ID in form/Messgrogramm
Evi Huber <ehuber@bfs.de>
parents:
1396
diff
changeset
|
86 name: 'id', |
e749d09fafca
show MPR-ID in form/Messgrogramm
Evi Huber <ehuber@bfs.de>
parents:
1396
diff
changeset
|
87 fieldLabel: i18n.getMsg('mprId'), |
e749d09fafca
show MPR-ID in form/Messgrogramm
Evi Huber <ehuber@bfs.de>
parents:
1396
diff
changeset
|
88 margin: '0, 5, 5, 5', |
e749d09fafca
show MPR-ID in form/Messgrogramm
Evi Huber <ehuber@bfs.de>
parents:
1396
diff
changeset
|
89 labelWidth: 95, |
e749d09fafca
show MPR-ID in form/Messgrogramm
Evi Huber <ehuber@bfs.de>
parents:
1396
diff
changeset
|
90 maxLength: 20 |
e749d09fafca
show MPR-ID in form/Messgrogramm
Evi Huber <ehuber@bfs.de>
parents:
1396
diff
changeset
|
91 }, { |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
92 layout: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
93 type: 'hbox', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
94 align: 'stretch' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
95 }, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
96 border: 0, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
97 items: [{ |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
98 xtype: 'messstellelabor', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
99 name: 'mstlabor', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
100 fieldLabel: 'Messstelle/Labor', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
101 margin: '0, 5, 5, 5', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
102 width: '35%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
103 labelWidth: 95, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
104 allowBlank: false, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
105 editable: true, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
106 listeners: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
107 select: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
108 fn: function(combo, newValue) { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
109 var mst = newValue[0].get('messStelle'); |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
110 var labor = newValue[0].get('laborMst'); |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
111 combo.up('fieldset').down('messstelle[name=mstId]').setValue(mst); |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
112 combo.up('fieldset').down('messstelle[name=laborMstId]').setValue(labor); |
1396
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
113 combo.up('fieldset').down('messprogrammland[name=mplId]').setValue(); |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
114 } |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
115 } |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
116 } |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
117 }, { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
118 xtype: 'messstelle', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
119 name: 'mstId', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
120 fieldLabel: 'Messstelle/Labor', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
121 margin: '0, 5, 5, 5', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
122 width: '35%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
123 labelWidth: 95, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
124 allowBlank: false, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
125 editable: true, |
1212
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
126 hidden: true, |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
127 listeners: { |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
128 validitychange: me.mstLaborValidity |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
129 } |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
130 }, { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
131 xtype: 'messstelle', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
132 name: 'laborMstId', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
133 fieldLabel: 'Messstelle/Labor', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
134 margin: '0, 5, 5, 5', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
135 width: '35%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
136 labelWidth: 95, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
137 allowBlank: false, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
138 editable: true, |
1212
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
139 hidden: true, |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
140 listeners: { |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
141 validitychange: me.mstLaborValidity |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
142 } |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
143 }, { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
144 xtype: 'netzbetreiber', |
1396
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
145 name: 'netzbetreiber', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
146 editable: false, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
147 readOnly: true, |
1235
d1f43f1e7e84
Fix setting Netzbetreiber in Messprogramm.
Tom Gottfried <tom@intevation.de>
parents:
1234
diff
changeset
|
148 isFormField: false, |
d1f43f1e7e84
Fix setting Netzbetreiber in Messprogramm.
Tom Gottfried <tom@intevation.de>
parents:
1234
diff
changeset
|
149 submitValue: false, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
150 fieldLabel: i18n.getMsg('netzbetreiberId'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
151 margin : '0, 5, 5, 5', |
1248
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
152 width : '45%', |
1235
d1f43f1e7e84
Fix setting Netzbetreiber in Messprogramm.
Tom Gottfried <tom@intevation.de>
parents:
1234
diff
changeset
|
153 labelWidth: 80 |
797
b8fd43021c29
Added a Window to alter Orte of a Messprogramm
Dustin Demuth <dustin@intevation.de>
parents:
793
diff
changeset
|
154 }, { |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
155 xtype: 'datenbasis', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
156 editable: false, |
1180
1ae5e4f0f2c8
Set allowBlank to false for mandatory fields to be filled by the user.
Tom Gottfried <tom@intevation.de>
parents:
1169
diff
changeset
|
157 allowBlank: false, |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
158 name: 'datenbasisId', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
159 fieldLabel: i18n.getMsg('datenbasisId'), |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
160 margin : '0, 5, 5, 5', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
161 width : '20%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
162 labelWidth: 65 |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
163 }] |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
164 }, { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
165 layout: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
166 type: 'hbox', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
167 align: 'stretch' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
168 }, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
169 border: 0, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
170 items: [{ |
1248
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
171 xtype: 'probenart', |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
172 editable: false, |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
173 name: 'probenartId', |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
174 fieldLabel: i18n.getMsg('probenartId'), |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
175 margin: '0, 5, 5, 5', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
176 width: '35%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
177 labelWidth: 95, |
1248
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
178 allowBlank: false |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
179 }, { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
180 xtype: 'betriebsart', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
181 name: 'baId', |
1108 | 182 margin: '0, 5, 5, 5', |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
183 fieldLabel: i18n.getMsg('baId'), |
1108 | 184 //anchor: '100%', |
1248
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
185 width: '45%', |
1108 | 186 labelWidth: 80 |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
187 }, { |
1248
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
188 xtype: 'chkbox', |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
189 name: 'test', |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
190 fieldLabel: i18n.getMsg('test'), |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
191 anchor: '100%', |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
192 margin : '0, 5, 5, 5', |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
193 width : '20%', |
ca241fb7fbfb
Removed messprogramm name and updated messprogramm form layout
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1235
diff
changeset
|
194 labelWidth: 30, |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
195 allowBlank: false |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
196 }] |
1252
5db7e8abfd61
Added field for kommentar in messprogramm.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1249
diff
changeset
|
197 }, { |
5db7e8abfd61
Added field for kommentar in messprogramm.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1249
diff
changeset
|
198 xtype: 'tfield', |
5db7e8abfd61
Added field for kommentar in messprogramm.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1249
diff
changeset
|
199 name: 'kommentar', |
5db7e8abfd61
Added field for kommentar in messprogramm.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1249
diff
changeset
|
200 fieldLabel: i18n.getMsg('kommentar'), |
5db7e8abfd61
Added field for kommentar in messprogramm.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1249
diff
changeset
|
201 width: '100%', |
5db7e8abfd61
Added field for kommentar in messprogramm.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1249
diff
changeset
|
202 margin: '0, 5, 5, 5', |
5db7e8abfd61
Added field for kommentar in messprogramm.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1249
diff
changeset
|
203 labelWidth: 95 |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
204 }] |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
205 }, { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
206 // Zeit |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
207 xtype: 'fieldset', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
208 title: i18n.getMsg('probenintervall'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
209 layout: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
210 type: 'vbox', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
211 align: 'stretch' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
212 }, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
213 items: [{ |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
214 xtype: 'fset', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
215 name: 'probenIntervallFieldset', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
216 layout: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
217 type: 'hbox', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
218 align: 'stretch' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
219 }, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
220 border: 0, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
221 margin: '0, 0, 0, 0', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
222 items: [{ |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
223 xtype: 'probenintervall', |
1180
1ae5e4f0f2c8
Set allowBlank to false for mandatory fields to be filled by the user.
Tom Gottfried <tom@intevation.de>
parents:
1169
diff
changeset
|
224 allowBlank: false, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
225 fieldLabel: i18n.getMsg('probenintervall'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
226 margin: '0, 10, 5, 5', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
227 labelWidth: 50, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
228 width: '40%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
229 name: 'probenintervall' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
230 }, { |
1168
40a07eb873bf
Add numberfield with error/warning functionality and use for Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1167
diff
changeset
|
231 xtype: 'numfield', |
1169
e552e82ceb8a
Teilintervall and offset must be integer.
Tom Gottfried <tom@intevation.de>
parents:
1168
diff
changeset
|
232 allowDecimals: false, |
1180
1ae5e4f0f2c8
Set allowBlank to false for mandatory fields to be filled by the user.
Tom Gottfried <tom@intevation.de>
parents:
1169
diff
changeset
|
233 allowBlank: false, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
234 fieldLabel: i18n.getMsg('teilintervallVon'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
235 margin: '0, 10, 5, 10', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
236 labelWidth: 90, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
237 width: '28%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
238 name: 'teilintervallVon', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
239 period: 'start' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
240 }, { |
1168
40a07eb873bf
Add numberfield with error/warning functionality and use for Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1167
diff
changeset
|
241 xtype: 'numfield', |
1169
e552e82ceb8a
Teilintervall and offset must be integer.
Tom Gottfried <tom@intevation.de>
parents:
1168
diff
changeset
|
242 allowDecimals: false, |
1180
1ae5e4f0f2c8
Set allowBlank to false for mandatory fields to be filled by the user.
Tom Gottfried <tom@intevation.de>
parents:
1169
diff
changeset
|
243 allowBlank: false, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
244 fieldLabel: i18n.getMsg('teilintervallBis'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
245 margin: '0, 15, 5, 5', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
246 labelWidth: 18, |
1108 | 247 width: '15%', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
248 name: 'teilintervallBis', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
249 period: 'end' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
250 }, { |
1168
40a07eb873bf
Add numberfield with error/warning functionality and use for Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1167
diff
changeset
|
251 xtype: 'numfield', |
1169
e552e82ceb8a
Teilintervall and offset must be integer.
Tom Gottfried <tom@intevation.de>
parents:
1168
diff
changeset
|
252 allowDecimals: false, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
253 margin: '0, 10, 5, 5', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
254 fieldLabel: i18n.getMsg('offset'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
255 labelWidth: 45, |
1108 | 256 width: '17%', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
257 name: 'intervallOffset' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
258 }] |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
259 }, { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
260 xtype: 'probenintervallslider', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
261 // fieldLabel: i18n.getMsg('intervall'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
262 // labelWidth: 70, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
263 pack: 'center', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
264 width: '70%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
265 margin: '0, 40, 10, 40', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
266 values: [0, 0] |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
267 //this will be overridden |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
268 // by setRecord |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
269 }, { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
270 xtype: 'fset', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
271 name: 'gueltigPeriodFieldset', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
272 layout: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
273 type: 'hbox', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
274 align: 'stretch' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
275 }, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
276 border: 0, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
277 items: [{ |
1199
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
278 xtype: 'dayofyear', |
1180
1ae5e4f0f2c8
Set allowBlank to false for mandatory fields to be filled by the user.
Tom Gottfried <tom@intevation.de>
parents:
1169
diff
changeset
|
279 allowBlank: false, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
280 fieldLabel: i18n.getMsg('gueltigVon'), |
1199
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
281 width: '50%', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
282 labelWidth: 90, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
283 name: 'gueltigVon', |
1199
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
284 border: false |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
285 }, { |
1199
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
286 xtype: 'dayofyear', |
1180
1ae5e4f0f2c8
Set allowBlank to false for mandatory fields to be filled by the user.
Tom Gottfried <tom@intevation.de>
parents:
1169
diff
changeset
|
287 allowBlank: false, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
288 fieldLabel: i18n.getMsg('gueltigBis'), |
1199
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
289 width: '50%', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
290 labelWidth: 40, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
291 name: 'gueltigBis', |
1199
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
292 border: false |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
293 }] |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
294 }] |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
295 }, { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
296 // Medium |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
297 xtype: 'fieldset', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
298 title: i18n.getMsg('medium'), |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
299 width: '100%', |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
300 items: [{ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
301 border: 0, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
302 layout: { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
303 type: 'vbox', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
304 align: 'stretch' |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
305 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
306 width: '100%', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
307 items: [{ |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
308 xtype: 'umwelt', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
309 name: 'umwId', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
310 fieldLabel: i18n.getMsg('umwId'), |
1385
3f499c52eee6
changed layout form/Messprogramm.js (Deskriptoren)
Evi Huber <ehuber@bfs.de>
parents:
1289
diff
changeset
|
311 labelWidth: 100, |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
312 editable: true, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
313 listeners: { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
314 dirtychange: { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
315 fn: this.updateOnChange, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
316 scope: me |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
317 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
318 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
319 }, { |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
320 border: 0, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
321 layout: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
322 type: 'hbox', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
323 align: 'stretch' |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
324 }, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
325 width: '100%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
326 items: [{ |
1385
3f499c52eee6
changed layout form/Messprogramm.js (Deskriptoren)
Evi Huber <ehuber@bfs.de>
parents:
1289
diff
changeset
|
327 xtype: 'tfield', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
328 maxLength: 38, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
329 enforceMaxLength: true, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
330 name: 'mediaDesk', |
1385
3f499c52eee6
changed layout form/Messprogramm.js (Deskriptoren)
Evi Huber <ehuber@bfs.de>
parents:
1289
diff
changeset
|
331 width: '58%', |
3f499c52eee6
changed layout form/Messprogramm.js (Deskriptoren)
Evi Huber <ehuber@bfs.de>
parents:
1289
diff
changeset
|
332 labelWidth: 100, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
333 fieldLabel: i18n.getMsg('mediaDesk'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
334 editable: false, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
335 readOnly: true, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
336 listeners: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
337 dirtychange: { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
338 fn: this.updateOnChange, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
339 scope: me |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
340 } |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
341 } |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
342 }, { |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
343 xtype: 'textfield', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
344 name: 'media', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
345 margin: '0, 10, 5, 10', |
1385
3f499c52eee6
changed layout form/Messprogramm.js (Deskriptoren)
Evi Huber <ehuber@bfs.de>
parents:
1289
diff
changeset
|
346 width: '42%', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
347 enforceMaxLength: true, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
348 editable: false, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
349 readOnly: true |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
350 }] |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
351 }, { |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
352 xtype: 'fieldset', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
353 title: i18n.getMsg('deskDetails'), |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
354 collapsible: true, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
355 collapsed: true, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
356 defaultType: 'textfield', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
357 layout: { |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
358 type: 'vbox', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
359 align: 'stretch' |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
360 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
361 items: this.buildDescriptors(), |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
362 listeners: { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
363 dirtychange: { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
364 fn: this.updateOnChange, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
365 scope: me |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
366 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
367 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
368 }] |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
369 }] |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
370 }, { |
1116
92c0fa2f29b0
complete some comboboxes in probe form and messprogramm form
Michael Stanko <mstanko@bfs.de>
parents:
1108
diff
changeset
|
371 xtype: 'probenehmer', |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
372 name: 'probeNehmerId', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
373 fieldLabel: i18n.getMsg('probeNehmerId'), |
1116
92c0fa2f29b0
complete some comboboxes in probe form and messprogramm form
Michael Stanko <mstanko@bfs.de>
parents:
1108
diff
changeset
|
374 margin: '0, 5, 5, 5', |
1258 | 375 //width: '100%', |
1116
92c0fa2f29b0
complete some comboboxes in probe form and messprogramm form
Michael Stanko <mstanko@bfs.de>
parents:
1108
diff
changeset
|
376 minValue: 0, |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
377 anchor: '100%', |
1116
92c0fa2f29b0
complete some comboboxes in probe form and messprogramm form
Michael Stanko <mstanko@bfs.de>
parents:
1108
diff
changeset
|
378 labelWidth: 95 |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
379 }, { |
1258 | 380 xtype: 'messprogrammland', |
381 name: 'mplId', | |
382 fieldLabel: 'Messprogramm-Land', | |
383 margin: '0, 5, 5, 5', | |
384 //width: '100%', | |
385 anchor: '100%', | |
1396
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
386 labelWidth: 115, |
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
387 listeners: { |
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
388 expand : { |
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
389 fn: function(combo) { |
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
390 Ext.StoreManager.get('messprogrammkategorie').clearFilter(); |
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
391 Ext.StoreManager.get('messprogrammkategorie').filter('netzbetreiberId', combo.up('fieldset').down('netzbetreiber[name=netzbetreiber]').getValue()); |
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
392 } |
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
393 } |
418b9afee700
changed MessprogrammKategorie pageSize and added filter for combo dependent on selected messstelle in probeform and messprogrammform
Evi Huber <ehuber@bfs.de>
parents:
1385
diff
changeset
|
394 } |
1258 | 395 }, { |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
396 xtype: 'textarea', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
397 name: 'probeKommentar', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
398 labelAlign: 'top', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
399 fieldLabel: i18n.getMsg('probeKommentar'), |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
400 width: '100%', |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
401 labelwidth: 135, |
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
402 anchor: '100%' |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
403 }] |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
404 }] |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
405 }]; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
406 this.callParent(arguments); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
407 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
408 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
409 populateIntervall: function(record, intervall) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
410 //intervall is an identifier of a intervall |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
411 // for instance H, M, J, ... |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
412 // Initialize the probenintervallslider |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
413 var s = this.down('probenintervallslider'); |
774 | 414 var i = this.getForm().findField('intervallOffset'); |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
415 var v = this.getForm().findField('teilintervallVon'); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
416 var b = this.getForm().findField('teilintervallBis'); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
417 var intervallstore = Ext.data.StoreManager.get('Probenintervall'); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
418 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
419 var svalUpper = null |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
420 var svalLower = null |
759
b7484c7da2d4
Unified the Messprogramm windows. Unfortunately the Roweditor of Messmethodengrid is broken in this commit. This is due to the fact that the Mmt store is noit autoloaded anymore
Dustin Demuth <dustin@intevation.de>
parents:
757
diff
changeset
|
421 var min = null |
b7484c7da2d4
Unified the Messprogramm windows. Unfortunately the Roweditor of Messmethodengrid is broken in this commit. This is due to the fact that the Mmt store is noit autoloaded anymore
Dustin Demuth <dustin@intevation.de>
parents:
757
diff
changeset
|
422 var max = null |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
423 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
424 if (!intervallstore) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
425 intervallstore = Ext.create('Lada.store.Probenintervall'); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
426 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
427 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
428 //It is likely that this method was not |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
429 // called from the controller, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
430 //and the probenintervall was not changed. |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
431 // Load the records in this case |
759
b7484c7da2d4
Unified the Messprogramm windows. Unfortunately the Roweditor of Messmethodengrid is broken in this commit. This is due to the fact that the Mmt store is noit autoloaded anymore
Dustin Demuth <dustin@intevation.de>
parents:
757
diff
changeset
|
432 if (!intervall && record) { |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
433 intervall = record.get('probenintervall', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
434 0, false, false, true); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
435 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
436 svalUpper = record.get('teilintervallBis'); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
437 svalLower = record.get('teilintervallVon'); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
438 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
439 |
1210
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
440 // subintervall is redundant to validity for yearly samples |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
441 if (intervall == 'J') { |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
442 svalUpper = this.getForm().findField('gueltigBis').getValue(); |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
443 svalLower = this.getForm().findField('gueltigVon').getValue(); |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
444 b.setReadOnly(true); |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
445 v.setReadOnly(true); |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
446 s.setDisabled(true); |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
447 } else { |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
448 b.setReadOnly(false); |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
449 v.setReadOnly(false); |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
450 s.setDisabled(false); |
a24de34d6423
Align subintervall with validity for yearly samples.
Tom Gottfried <tom@intevation.de>
parents:
1199
diff
changeset
|
451 } |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
452 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
453 var intrec = intervallstore |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
454 .findRecord('probenintervall', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
455 intervall, 0, false, false, true); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
456 |
759
b7484c7da2d4
Unified the Messprogramm windows. Unfortunately the Roweditor of Messmethodengrid is broken in this commit. This is due to the fact that the Mmt store is noit autoloaded anymore
Dustin Demuth <dustin@intevation.de>
parents:
757
diff
changeset
|
457 if (intrec) { // in cases when a new messprogramm is |
1289
bfdc00c24baf
Ortszuordnung for messprogramm and probe using same form
Maximilian Krambach <mkrambach@intevation.de>
parents:
1276
diff
changeset
|
458 // created and the discard function is used, intrec will be null && edit is allowed |
759
b7484c7da2d4
Unified the Messprogramm windows. Unfortunately the Roweditor of Messmethodengrid is broken in this commit. This is due to the fact that the Mmt store is noit autoloaded anymore
Dustin Demuth <dustin@intevation.de>
parents:
757
diff
changeset
|
459 // consequently the assertion below will fail. |
b7484c7da2d4
Unified the Messprogramm windows. Unfortunately the Roweditor of Messmethodengrid is broken in this commit. This is due to the fact that the Mmt store is noit autoloaded anymore
Dustin Demuth <dustin@intevation.de>
parents:
757
diff
changeset
|
460 min = intrec.get('periodstart'); |
b7484c7da2d4
Unified the Messprogramm windows. Unfortunately the Roweditor of Messmethodengrid is broken in this commit. This is due to the fact that the Mmt store is noit autoloaded anymore
Dustin Demuth <dustin@intevation.de>
parents:
757
diff
changeset
|
461 max = intrec.get('periodend'); |
b7484c7da2d4
Unified the Messprogramm windows. Unfortunately the Roweditor of Messmethodengrid is broken in this commit. This is due to the fact that the Mmt store is noit autoloaded anymore
Dustin Demuth <dustin@intevation.de>
parents:
757
diff
changeset
|
462 } |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
463 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
464 if (!svalUpper) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
465 svalUpper = max; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
466 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
467 if (!svalLower) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
468 svalLower = min; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
469 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
470 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
471 //Set Teilintervalle |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
472 v.setMinValue(min); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
473 v.setMaxValue(max); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
474 b.setMinValue(min); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
475 b.setMaxValue(max); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
476 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
477 //Set Slider |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
478 s.setMinValue(min); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
479 s.setMaxValue(max); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
480 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
481 v.setValue(svalLower); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
482 b.setValue(svalUpper); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
483 |
774 | 484 //Set IntervallOffset |
485 i.setMinValue(0); | |
486 i.setMaxValue(max-1); | |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
487 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
488 |
1212
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
489 /* |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
490 * Set validity of messstellelabor field (not part of the form) based |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
491 * on validitychange event of hidden mstId and laborMstId |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
492 */ |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
493 mstLaborValidity: function(field, isValid) { |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
494 if (!isValid) { |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
495 field.up('fieldset').down('messstellelabor') |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
496 .down('combobox').markInvalid(''); |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
497 } |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
498 }, |
3e6756b0fc97
Fix and complement validation of Messprogramm from.
Tom Gottfried <tom@intevation.de>
parents:
1210
diff
changeset
|
499 |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
500 setRecord: function(messRecord) { |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
501 this.clearMessages(); |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
502 this.getForm().loadRecord(messRecord); |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
503 //Set the intervall numberfields and the slider. |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
504 this.down('probenintervallslider').setValue([ |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
505 messRecord.get('teilintervallVon'), |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
506 messRecord.get('teilintervallBis') |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
507 ]); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
508 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
509 //TODO Set Sliders MinMaxValue |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
510 this.populateIntervall(messRecord); |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
511 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
512 this.down('probenintervallslider').on( |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
513 'change', |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
514 Lada.app.getController('Lada.controller.form.Messprogramm') |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
515 .synchronizeFields |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
516 ); |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
517 var mstStore = Ext.data.StoreManager.get('messstellen'); |
1235
d1f43f1e7e84
Fix setting Netzbetreiber in Messprogramm.
Tom Gottfried <tom@intevation.de>
parents:
1234
diff
changeset
|
518 var mstId = mstStore.getById(messRecord.get('mstId')); |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
519 if (!messRecord.get('owner')) { |
1071
116b9629eb2c
Fixed mstId in new messprogramm dialog.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1068
diff
changeset
|
520 if (!mstId) { |
116b9629eb2c
Fixed mstId in new messprogramm dialog.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1068
diff
changeset
|
521 return; |
116b9629eb2c
Fixed mstId in new messprogramm dialog.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1068
diff
changeset
|
522 } |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
523 var laborMstId = mstStore.getById(messRecord.get('laborMstId')); |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
524 if (laborMstId) { |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
525 laborMstId = laborMstId.get('messStelle'); |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
526 } |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
527 else { |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
528 laborMstId = ''; |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
529 } |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
530 var id = this.down('messstellelabor').store.count() + 1; |
1276
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
531 if ( messRecord.get('mstId') === messRecord.get('laborMstId') ) { |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
532 displayCombi = mstId.get('messStelle'); |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
533 } else { |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
534 displayCombi = mstId.get('messStelle') + '/' + laborMstId |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
535 |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
536 } |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
537 var newStore = Ext.create('Ext.data.Store', { |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
538 model: 'Lada.model.MessstelleLabor', |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
539 data: [{ |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
540 id: id, |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
541 laborMst: messRecord.get('laborMstId'), |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
542 messStelle: messRecord.get('mstId'), |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
543 displayCombi: displayCombi |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
544 }] |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
545 }); |
1067
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
546 this.down('messstellelabor').down('combobox').store = newStore; |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
547 this.down('messstellelabor').setValue(id); |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
548 } |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
549 else { |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
550 var mstLaborStore = Ext.data.StoreManager.get('messstellelabor'); |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
551 var items = mstLaborStore.queryBy(function(record) { |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
552 if (record.get('messStelle') === messRecord.get('mstId') && |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
553 record.get('laborMst') === messRecord.get('laborMstId')) { |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
554 return true; |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
555 } |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
556 }); |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
557 this.down('messstellelabor').setValue(items.getAt(0)); |
3da8e8b973ad
Use the laborMstId to generate probe objects.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
894
diff
changeset
|
558 } |
1235
d1f43f1e7e84
Fix setting Netzbetreiber in Messprogramm.
Tom Gottfried <tom@intevation.de>
parents:
1234
diff
changeset
|
559 this.down('netzbetreiber').setValue(mstId.get('netzbetreiberId')); |
784
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
560 }, |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
561 |
784
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
562 setMediaDesk: function(record) { |
1234
390dabbf27ed
Empty string for media descriptor is disallowed.
Tom Gottfried <tom@intevation.de>
parents:
1212
diff
changeset
|
563 var media = record.get('mediaDesk'); |
390dabbf27ed
Empty string for media descriptor is disallowed.
Tom Gottfried <tom@intevation.de>
parents:
1212
diff
changeset
|
564 if (media) { |
390dabbf27ed
Empty string for media descriptor is disallowed.
Tom Gottfried <tom@intevation.de>
parents:
1212
diff
changeset
|
565 var mediaParts = media.split(' '); |
390dabbf27ed
Empty string for media descriptor is disallowed.
Tom Gottfried <tom@intevation.de>
parents:
1212
diff
changeset
|
566 this.setMediaSN(0, mediaParts); |
390dabbf27ed
Empty string for media descriptor is disallowed.
Tom Gottfried <tom@intevation.de>
parents:
1212
diff
changeset
|
567 } |
784
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
568 }, |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
569 |
1108 | 570 setMediaSN: function(ndx, media, beschreibung) { |
571 var mediabeschreibung = this.getForm().findField('media'); | |
784
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
572 if (ndx >= 12) { |
1276
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
573 mediabeschreibung.setValue(beschreibung); |
784
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
574 return; |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
575 } |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
576 var me = this; |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
577 var current = this.down('deskriptor[layer=' + ndx + ']'); |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
578 var cbox = current.down('combobox'); |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
579 if (ndx === 0) { |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
580 cbox.store.proxy.extraParams = { |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
581 'layer': ndx |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
582 }; |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
583 } |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
584 else { |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
585 var parents = current.getParents(current.down('combobox')); |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
586 if (parents.length === 0) { |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
587 return; |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
588 } |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
589 cbox.store.proxy.extraParams = { |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
590 'layer': ndx, |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
591 'parents': parents |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
592 }; |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
593 } |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
594 cbox.store.load(function(records, op, success) { |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
595 if (!success) { |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
596 return; |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
597 } |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
598 cbox.select(cbox.store.findRecord('sn', parseInt(media[ndx + 1], 10))); |
1276
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
599 var mediatext = cbox.store.findRecord('sn', parseInt(media[ndx + 1], 10)); |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
600 if (mediatext !== null) { |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
601 if ( (ndx <= 3) && (media[1] === '01') && (mediatext.data.beschreibung !== "leer") ) { |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
602 beschreibung = mediatext.data.beschreibung; |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
603 } else if ( (media[1] !== '01') && (mediatext.data.beschreibung !== "leer") && (ndx <= 1) ) { |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
604 beschreibung = mediatext.data.beschreibung; |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
605 } |
8f37f8832c4a
fix mediadescription in probe form
Michael Stanko <mstanko@bfs.de>
parents:
1258
diff
changeset
|
606 } |
1108 | 607 me.setMediaSN(++ndx, media, beschreibung); |
784
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
608 }); |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
609 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
610 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
611 setMessages: function(errors, warnings) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
612 var key; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
613 var element; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
614 var content; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
615 var i18n = Lada.getApplication().bundle; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
616 if (warnings) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
617 for (key in warnings) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
618 element = this.down('component[name=' + key + ']'); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
619 if (!element) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
620 continue; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
621 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
622 content = warnings[key]; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
623 var warnText = ''; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
624 for (var i = 0; i < content.length; i++) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
625 warnText += i18n.getMsg(content[i].toString()) + '\n'; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
626 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
627 element.showWarnings(warnText); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
628 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
629 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
630 if (errors) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
631 for (key in errors) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
632 element = this.down('component[name=' + key + ']'); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
633 if (!element) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
634 continue; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
635 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
636 content = errors[key]; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
637 var errorText = ''; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
638 for (var i = 0; i < content.length; i++) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
639 errorText += i18n.getMsg(content[i].toString()) + '\n'; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
640 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
641 element.showErrors(errorText); |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
642 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
643 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
644 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
645 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
646 clearMessages: function() { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
647 // TODO |
1068
096d552508cd
Set readonly state for messstelle-labor widget.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
1067
diff
changeset
|
648 this.down('cbox[name=mstlabor]').clearWarningOrError(); |
777 | 649 //no clearmsg for probeKommentar |
650 this.down('cbox[name=datenbasisId]').clearWarningOrError(); | |
651 this.down('cbox[name=baId]').clearWarningOrError(); | |
1086
61cc583c3649
Messprogramm form redesign
Michael Stanko <mstanko@bfs.de>
parents:
1071
diff
changeset
|
652 this.down('chkbox[name=test]').clearWarningOrError(); |
777 | 653 this.down('cbox[name=probenartId]').clearWarningOrError(); |
1235
d1f43f1e7e84
Fix setting Netzbetreiber in Messprogramm.
Tom Gottfried <tom@intevation.de>
parents:
1234
diff
changeset
|
654 this.down('netzbetreiber').clearWarningOrError(); |
1167
e9bf88db2bbb
Complement clearing of Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1116
diff
changeset
|
655 // clear messages in intervall definition |
e9bf88db2bbb
Complement clearing of Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1116
diff
changeset
|
656 this.down('fset[name=probenIntervallFieldset]').clearMessages(); |
e9bf88db2bbb
Complement clearing of Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1116
diff
changeset
|
657 this.down('cbox[name=probenintervall]').clearWarningOrError(); |
1168
40a07eb873bf
Add numberfield with error/warning functionality and use for Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1167
diff
changeset
|
658 this.down('numfield[name=teilintervallVon]').clearWarningOrError(); |
40a07eb873bf
Add numberfield with error/warning functionality and use for Messprogramm form.
Tom Gottfried <tom@intevation.de>
parents:
1167
diff
changeset
|
659 this.down('numfield[name=teilintervallBis]').clearWarningOrError(); |
1199
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
660 this.down('dayofyear[name=gueltigVon]').clearWarningOrError(); |
0a7f0a09151c
Replace date-time picker with appropriate widget to select day of year.
Tom Gottfried <tom@intevation.de>
parents:
1180
diff
changeset
|
661 this.down('dayofyear[name=gueltigBis]').clearWarningOrError(); |
777 | 662 //no clear for probeNehmerId |
663 // Deskriptoren are missing | |
664 this.down('cbox[name=umwId]').clearWarningOrError(); | |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
665 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
666 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
667 setReadOnly: function(value) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
668 // TODO |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
669 }, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
670 |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
671 buildDescriptors: function() { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
672 var fields = []; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
673 for (var i = 0; i < 12; i++) { |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
674 fields[i] = { |
784
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
675 xtype: 'deskriptor', |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
676 fieldLabel: 'S' + i, |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
677 labelWidth: 25, |
784
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
678 width: 190, |
f0b26df02157
Handle deskriptoren in messprogramm like in probe.
Raimund Renkert <raimund.renkert@intevation.de>
parents:
779
diff
changeset
|
679 layer: i, |
757
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
680 margin: '0, 10, 5, 0' |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
681 }; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
682 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
683 return fields; |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
684 } |
b8502964f5c3
Added missing files. Added MmtMockup
Dustin Demuth <dustin@intevation.de>
parents:
diff
changeset
|
685 }); |