comparison app/view/form/Ort.js @ 603:9d0113bc2f70

Added ort form and controller.
author Raimund Renkert <raimund.renkert@intevation.de>
date Thu, 12 Mar 2015 15:51:24 +0100
parents
children 2ad36c8db968
comparison
equal deleted inserted replaced
602:e1ab24758392 603:9d0113bc2f70
1 /* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
2 * Software engineering by Intevation GmbH
3 *
4 * This file is Free Software under the GNU GPL (v>=3)
5 * and comes with ABSOLUTELY NO WARRANTY! Check out
6 * the documentation coming with IMIS-Labordaten-Application for details.
7 */
8
9 /*
10 * Formular to edit a Probe
11 */
12 Ext.define('Lada.view.form.Ort', {
13 extend: 'Ext.form.Panel',
14 alias: 'widget.ortform',
15
16 requires: [
17 'Lada.view.widget.Location'
18 ],
19
20 model: 'Lada.model.Ort',
21 minWidth: 300,
22 margin: 5,
23 border: 0,
24
25 recordId: null,
26
27 trackResetOnLoad: true,
28
29 initComponent: function() {
30 this.items = [{
31 xtype: 'fieldset',
32 title: 'Ort',
33 items: [{
34 border: 0,
35 margin: '0, 0, 10, 0',
36 dockedItems: [{
37 xtype: 'toolbar',
38 dock: 'bottom',
39 border: '0, 1, 1, 1',
40 style: {
41 borderBottom: '1px solid #b5b8c8 !important',
42 borderLeft: '1px solid #b5b8c8 !important',
43 borderRight: '1px solid #b5b8c8 !important'
44 },
45 items: ['->', {
46 text: 'Speichern',
47 qtip: 'Daten speichern',
48 icon: 'resources/img/dialog-ok-apply.png',
49 action: 'save',
50 disabled: true
51 }, {
52 text: 'Verwerfen',
53 qtip: 'Ă„nderungen verwerfen',
54 icon: 'resources/img/dialog-cancel.png',
55 action: 'discard',
56 disabled: true
57 }]
58 }],
59 items: [{
60 xtype: 'location',
61 name: 'ort',
62 fieldLabel: 'Ort',
63 labelWidth: 80,
64 width: 280
65 }, {
66 xtype: 'tfield',
67 name: 'ortsTyp',
68 fieldLabel: 'Typ',
69 labelWidth: 80,
70 width: 280,
71 maxLength: 1
72 }, {
73 xtype: 'textarea',
74 name: 'ortszusatztext',
75 fieldLabel: 'Ortszusatz',
76 width: 280,
77 labelWidth: 80
78 }]
79 }]
80 }];
81 this.callParent(arguments);
82 },
83
84 setRecord: function(record) {
85 this.getForm().loadRecord(record);
86 },
87
88 setMessages: function(errors, warnings) {
89 },
90
91 clearMessages: function() {
92 },
93
94 setReadOnly: function(value) {
95 }
96 });

http://lada.wald.intevation.org