annotate app/view/grid/Orte.js @ 1369:1cc11bada44e

fix rowediting trigger in ortstammdatengrid and proper reloading after save
author Maximilian Krambach <mkrambach@intevation.de>
date Wed, 08 Feb 2017 17:26:24 +0100
parents 993e542796fd
children 3da3772272a5
rev   line source
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
1 /* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
2 * Software engineering by Intevation GmbH
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
3 *
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
4 * This file is Free Software under the GNU GPL (v>=3)
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
5 * and comes with ABSOLUTELY NO WARRANTY! Check out
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
6 * the documentation coming with IMIS-Labordaten-Application for details.
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
7 */
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
8
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
9 /**
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
10 * Grid to list Orte Stammdaten
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
11 */
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
12 Ext.define('Lada.view.grid.Orte', {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
13 extend: 'Ext.grid.Panel',
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
14 alias: 'widget.ortstammdatengrid',
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
15
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
16 requires: [
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
17 'Ext.ux.grid.FiltersFeature',
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
18 'Lada.view.widget.KoordinatenArt',
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
19 'Lada.view.widget.Kta',
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
20 'Lada.view.widget.OrtsZusatz',
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
21 'Lada.view.widget.OrtTyp'
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
22 ],
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
23 // minHeight and deferEmptyText are needed to be able to show the
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
24 // emptyText message.
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
25 minHeight: 110,
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
26 viewConfig: {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
27 deferEmptyText: false
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
28 },
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
29
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
30 recordId: null,
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
31
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
32 warnings: null,
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
33 errors: null,
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
34 readOnly: true,
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
35 allowDeselect: true,
1050
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
36 editableGrid: true,
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
37 features: [],
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
38
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
39 initComponent: function() {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
40 var i18n = Lada.getApplication().bundle;
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
41 this.emptyText = i18n.getMsg('orte.emptyGrid');
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
42
1050
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
43 if (this.editableGrid) {
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
44 this.rowEditing = Ext.create('Ext.grid.plugin.RowEditing', {
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
45 clicksToMoveEditor: 1,
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
46 autoCancel: false,
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
47 disabled: false,
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
48 pluginId: 'rowedit'
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
49 });
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
50 this.plugins = [this.rowEditing];
e0b5e64928c9 Use rowediting plugin for orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1049
diff changeset
51 }
1049
1bd4c0709bd6 Working version of selectable 'ort' in map and grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1021
diff changeset
52
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
53 filters = {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
54 ftype: 'filters',
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
55 // encode and local configuration options defined previously for easier reuse
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
56 encode: false, // json encode the filter query
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
57 local: true, // defaults to false (remote filtering)
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
58
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
59 // Filters are most naturally placed in the column definition, but can also be
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
60 // added here.
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
61 filters: [{
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
62 type: 'boolean',
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
63 dataIndex: 'visible'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
64 }]
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
65 };
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
66 this.features = [filters];
1369
1cc11bada44e fix rowediting trigger in ortstammdatengrid and proper reloading after save
Maximilian Krambach <mkrambach@intevation.de>
parents: 1366
diff changeset
67 var me = this;
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
68 this.columns = [{
1081
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
69 xtype: 'actioncolumn',
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
70 text: 'RW',
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
71 dataIndex: 'readonly',
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
72 sortable: false,
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
73 width: 30,
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
74 getClass: function (val, meta, rec) {
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
75 if (rec.get('readonly') === false) {
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
76 return 'edit';
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
77 }
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
78 return 'noedit';
1369
1cc11bada44e fix rowediting trigger in ortstammdatengrid and proper reloading after save
Maximilian Krambach <mkrambach@intevation.de>
parents: 1366
diff changeset
79 },
1cc11bada44e fix rowediting trigger in ortstammdatengrid and proper reloading after save
Maximilian Krambach <mkrambach@intevation.de>
parents: 1366
diff changeset
80 handler: function(grid, rowIndex, colIndex) {
1cc11bada44e fix rowediting trigger in ortstammdatengrid and proper reloading after save
Maximilian Krambach <mkrambach@intevation.de>
parents: 1366
diff changeset
81 var rec = grid.getStore().getAt(rowIndex);
1cc11bada44e fix rowediting trigger in ortstammdatengrid and proper reloading after save
Maximilian Krambach <mkrambach@intevation.de>
parents: 1366
diff changeset
82 if (rec.get('readonly') === false) {
1cc11bada44e fix rowediting trigger in ortstammdatengrid and proper reloading after save
Maximilian Krambach <mkrambach@intevation.de>
parents: 1366
diff changeset
83 me.rowEditing.startEdit(rowIndex, colIndex);
1cc11bada44e fix rowediting trigger in ortstammdatengrid and proper reloading after save
Maximilian Krambach <mkrambach@intevation.de>
parents: 1366
diff changeset
84 }
1081
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
85 }
5e9a674d7bb4 Added Icon-column to stammdaten grid showing RW-status.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1050
diff changeset
86 }, {
1135
6408811c5c41 Fix i18n-String.
Tom Gottfried <tom@intevation.de>
parents: 1130
diff changeset
87 header: i18n.getMsg('netzbetreiberId'),
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
88 renderer: function(value) {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
89 var r = '';
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
90 if (!value || value === '') {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
91 r = 'Error';
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
92 }
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
93 var store = Ext.data.StoreManager.get('netzbetreiber');
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
94 var record = store.getById(value);
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
95 if (record) {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
96 r = record.get('netzbetreiber');
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
97 }
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
98 return r;
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
99 },
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
100 editor: {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
101 xtype: 'combobox',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
102 store: Ext.data.StoreManager.get('netzbetreiberFiltered'),
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
103 displayField: 'netzbetreiber',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
104 valueField: 'id',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
105 allowBlank: false
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
106 },
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
107 dataIndex: 'netzbetreiberId'
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
108 }, {
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
109 header: i18n.getMsg('orte.ortId'),
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
110 editor: {
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
111 xtype: 'textfield',
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
112 maxLength: 10,
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
113 allowBlank: false
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
114 },
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
115 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
116 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
117 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
118 dataIndex: 'ortId'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
119 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
120 header: i18n.getMsg('orte.nutsCode'),
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
121 editor: {
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
122 xtype: 'textfield',
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
123 maxLength: 10
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
124 },
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
125 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
126 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
127 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
128 dataIndex: 'nutsCode'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
129 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
130 header: i18n.getMsg('orte.anlageId'),
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
131 editor: {
1325
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
132 xtype: 'combobox',
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
133 store: Ext.data.StoreManager.get('ktas'),
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
134 displayField: 'code',
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
135 valueField: 'id'
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
136 },
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
137 renderer: function(value) {
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
138 if (value === undefined ||
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
139 value === null ||
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
140 value === ''
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
141 ) {
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
142 return '';
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
143 }
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
144 var store = Ext.data.StoreManager.get('ktas');
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
145 var record = store.getById(value);
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
146 return record.get('code');
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
147 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
148 dataIndex: 'anlageId'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
149 }, {
1297
5dfd5798cbcc i18n-wording
Tom Gottfried <tom@intevation.de>
parents: 1296
diff changeset
150 header: i18n.getMsg('orte.verwaltungseinheit'),
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
151 dataIndex: 'gemId',
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
152 width: 120,
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
153 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
154 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
155 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
156 renderer: function(value) {
1345
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
157 if (value === undefined ||
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
158 value === null ||
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
159 value === ''
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
160 ) {
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
161 return '';
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
162 }
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
163 var store = Ext.data.StoreManager.get('verwaltungseinheiten');
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
164 var record = store.getById(value);
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
165 return record.get('bezeichnung');
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
166 },
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
167 editor: {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
168 xtype: 'combobox',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
169 store: Ext.data.StoreManager.get('verwaltungseinheiten'),
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
170 displayField: 'bezeichnung',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
171 valueField: 'id',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
172 allowBlank: false
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
173 }
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
174 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
175 header: i18n.getMsg('orte.staatId'),
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
176 dataIndex: 'staatId',
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
177 width: 70,
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
178 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
179 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
180 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
181 renderer: function(value) {
1345
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
182 if (value === undefined ||
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
183 value === null ||
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
184 value === ''
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
185 ) {
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
186 return '';
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
187 }
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
188 var staaten = Ext.data.StoreManager.get('staaten');
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
189 var record = staaten.getById(value);
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
190 return record.get('staatIso');
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
191 },
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
192 editor: {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
193 xtype: 'combobox',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
194 store: Ext.data.StoreManager.get('staaten'),
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
195 displayField: 'staatIso',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
196 valueField: 'id',
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
197 allowBlank: false
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
198 }
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
199 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
200 header: i18n.getMsg('orte.kdaId'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
201 filter: {
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
202 type: 'string'
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
203 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
204 editor: {
1325
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
205 xtype: 'combobox',
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
206 store: Ext.data.StoreManager.get('koordinatenart'),
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
207 displayField: 'koordinatenart',
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
208 valueField: 'id'
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
209 },
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
210 renderer: function(value) {
1345
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
211 if (value === undefined ||
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
212 value === null ||
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
213 value === ''
da98f0e7c288 Check for empty values in ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1325
diff changeset
214 ) {
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
215 return '';
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
216 }
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
217 var kda = Ext.data.StoreManager.get('koordinatenart');
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
218 var record = kda.getById(value);
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
219 return record.get('koordinatenart');
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
220 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
221 dataIndex: 'kdaId'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
222 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
223 header: i18n.getMsg('orte.ozId'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
224 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
225 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
226 },
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
227 editor: {
1325
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
228 xtype: 'combobox',
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
229 store: Ext.data.StoreManager.get('ortszusatz'),
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
230 displayField: 'ozsId',
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
231 valueField: 'ozsId'
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
232 },
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
233 renderer: function(value) {
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
234 if (value === undefined ||
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
235 value === null ||
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
236 value === ''
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
237 ) {
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
238 return '';
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
239 }
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
240 var oz = Ext.data.StoreManager.get('ortszusatz');
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
241 var record = oz.getById(value);
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
242 return record.get('ozsId');
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
243 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
244 dataIndex: 'ozId'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
245 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
246 header: i18n.getMsg('orte.ortTyp'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
247 filter: {
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
248 type: 'string'
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
249 },
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
250 editor: {
1325
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
251 xtype: 'combobox',
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
252 store: Ext.data.StoreManager.get('orttyp'),
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
253 displayField: 'code',
35bbbfbe130c Changed ort grid editors from custom to default comboboxes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1317
diff changeset
254 valueField: 'id'
1317
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
255 },
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
256 renderer: function(value) {
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
257 if (value === undefined ||
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
258 value === null ||
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
259 value === ''
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
260 ) {
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
261 return '';
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
262 }
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
263 var ot = Ext.data.StoreManager.get('orttyp');
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
264 var record = ot.getById(value);
46093e6f45d2 Use the new stammdaten to display and edit ort attributes.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1308
diff changeset
265 return record.get('code');
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
266 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
267 dataIndex: 'ortTyp'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
268 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
269 header: i18n.getMsg('orte.mpArt'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
270 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
271 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
272 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
273 editor: {
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
274 xtype: 'textfield',
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
275 maxLength: 10
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
276 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
277 dataIndex: 'mpArt'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
278 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
279 header: i18n.getMsg('orte.zone'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
280 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
281 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
282 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
283 editor: {
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
284 xtype: 'textfield',
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
285 maxLength: 1
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
286 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
287 dataIndex: 'zone'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
288 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
289 header: i18n.getMsg('orte.sektor'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
290 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
291 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
292 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
293 editor: {
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
294 xtype: 'textfield',
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
295 maxLength: 2
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
296 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
297 dataIndex: 'sektor'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
298 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
299 header: i18n.getMsg('orte.zustaendigkeit'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
300 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
301 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
302 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
303 editor: {
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
304 xtype: 'textfield',
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
305 maxLength: 10
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
306 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
307 dataIndex: 'zustaendigkeit'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
308 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
309 header: i18n.getMsg('orte.berichtstext'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
310 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
311 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
312 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
313 editor: {
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
314 xtype: 'textfield',
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
315 maxLength: 70
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
316 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
317 dataIndex: 'berichtstext'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
318 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
319 header: i18n.getMsg('orte.kurztext'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
320 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
321 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
322 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
323 editor: {
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
324 xtype: 'textfield',
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
325 maxLength: 15,
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
326 allowBlank: false
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
327 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
328 dataIndex: 'kurztext'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
329 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
330 header: i18n.getMsg('orte.langtext'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
331 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
332 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
333 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
334 editor: {
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
335 xtype: 'textfield',
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
336 maxLength: 100,
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
337 allowBlank: false
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
338 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
339 dataIndex: 'langtext'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
340 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
341 header: i18n.getMsg('orte.unscharf'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
342 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
343 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
344 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
345 editor: {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
346 xtype: 'textfield'
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
347 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
348 dataIndex: 'unscharf'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
349 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
350 header: i18n.getMsg('orte.hoeheLand'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
351 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
352 type: 'numeric'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
353 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
354 editor: {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
355 xtype: 'numberfield'
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
356 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
357 dataIndex: 'hoeheLand'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
358 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
359 header: i18n.getMsg('orte.koordXExtern'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
360 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
361 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
362 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
363 editor: {
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
364 xtype: 'textfield',
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
365 maxLength: 22,
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
366 allowBlank: false
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
367 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
368 dataIndex: 'koordXExtern'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
369 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
370 header: i18n.getMsg('orte.koordYExtern'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
371 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
372 type: 'string'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
373 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
374 editor: {
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
375 xtype: 'textfield',
1254
6321530e640e Make it a bit easier to create a valid new Ort.
Tom Gottfried <tom@intevation.de>
parents: 1141
diff changeset
376 maxLength: 22,
1140
450368f67858 Set requiered fields for stammdaten.ort grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1130
diff changeset
377 allowBlank: false
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
378 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
379 dataIndex: 'koordYExtern'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
380 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
381 header: i18n.getMsg('orte.longitude'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
382 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
383 type: 'numeric'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
384 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
385 editor: {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
386 xtype: 'numberfield'
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
387 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
388 dataIndex: 'longitude'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
389 }, {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
390 header: i18n.getMsg('orte.latitude'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
391 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
392 type: 'numeric'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
393 },
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
394 editor: {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
395 xtype: 'numberfield'
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
396 },
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
397 dataIndex: 'latitude'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
398 }, {
1137
53d108efab0b Format letzteAenderung in Orte grid.
Tom Gottfried <tom@intevation.de>
parents: 1136
diff changeset
399 header: i18n.getMsg('letzteAenderung'),
1308
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
400 filter: {
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
401 type: 'date'
6075731bc4f1 Added column filter to orte grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1297
diff changeset
402 },
1137
53d108efab0b Format letzteAenderung in Orte grid.
Tom Gottfried <tom@intevation.de>
parents: 1136
diff changeset
403 xtype: 'datecolumn',
53d108efab0b Format letzteAenderung in Orte grid.
Tom Gottfried <tom@intevation.de>
parents: 1136
diff changeset
404 format: 'd.m.Y H:i',
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
405 dataIndex: 'letzteAenderung'
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
406 }];
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
407 this.callParent(arguments);
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
408 },
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
409
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
410 /**
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
411 * This sets the Store of this Grid
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
412 */
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
413 setStore: function(store){
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
414 var i18n = Lada.getApplication().bundle;
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
415
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
416 if (store) {
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
417 this.reconfigure(store);
1021
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
418
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
419 var ptbar = this.down('pagingtoolbar');
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
420 if (ptbar) {
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
421 this.removeDocked(ptbar);
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
422 }
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
423
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
424 if (store.pageSize > 0) {
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
425 this.addDocked([{
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
426 xtype: 'pagingtoolbar',
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
427 dock: 'bottom',
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
428 store: store,
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
429 displayInfo: true
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
430 }]);
1df6b6210b42 WIP First Version of a New Window/Panel combination to edit Ortszuordnungen and Orte
Dustin Demuth <dustin@intevation.de>
parents: 1011
diff changeset
431 }
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
432 }
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
433
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
434 if (Ext.Array.contains(Lada.funktionen, 4)) {
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
435 var panel = this.up('ortpanel');
1366
993e542796fd Fixed type error in ortszuordnung when user has 'funktion = 4'
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1345
diff changeset
436 // We are not in stammdaten editor.
993e542796fd Fixed type error in ortszuordnung when user has 'funktion = 4'
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1345
diff changeset
437 if (!panel) {
993e542796fd Fixed type error in ortszuordnung when user has 'funktion = 4'
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1345
diff changeset
438 return;
993e542796fd Fixed type error in ortszuordnung when user has 'funktion = 4'
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1345
diff changeset
439 }
1130
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
440 panel.down('button[action=add]').enable();
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
441 panel.down('button[action=addMap]').enable();
e4952906634d Implemented insert, edit and delete for stammdaten.ort.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1081
diff changeset
442 }
1049
1bd4c0709bd6 Working version of selectable 'ort' in map and grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1021
diff changeset
443 },
1bd4c0709bd6 Working version of selectable 'ort' in map and grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1021
diff changeset
444
1bd4c0709bd6 Working version of selectable 'ort' in map and grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1021
diff changeset
445 selectOrt: function(map, feature) {
1bd4c0709bd6 Working version of selectable 'ort' in map and grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1021
diff changeset
446 var id = feature[0].data.id;
1bd4c0709bd6 Working version of selectable 'ort' in map and grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1021
diff changeset
447 var record = this.store.getById(id);
1bd4c0709bd6 Working version of selectable 'ort' in map and grid.
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1021
diff changeset
448 this.getSelectionModel().select(record);
1293
16a80ca16732 map feature visibility, selection and grid layout
Maximilian Krambach <mkrambach@intevation.de>
parents: 1254
diff changeset
449 var win = this.up('ortszuordnungwindow');
16a80ca16732 map feature visibility, selection and grid layout
Maximilian Krambach <mkrambach@intevation.de>
parents: 1254
diff changeset
450 if (win){
16a80ca16732 map feature visibility, selection and grid layout
Maximilian Krambach <mkrambach@intevation.de>
parents: 1254
diff changeset
451 win.down('ortszuordnungform').setOrt(null, record);
16a80ca16732 map feature visibility, selection and grid layout
Maximilian Krambach <mkrambach@intevation.de>
parents: 1254
diff changeset
452 }
1004
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
453 }
9ac03f461ab4 Introduced Orte into Stammdatengrids, Added Ortszuordnung. THIS COMMIT IS WORK IN PROGRESS, Proben will NOT work after this commit. Orte can not be edited.
Dustin Demuth <dustin@intevation.de>
parents:
diff changeset
454 });

http://lada.wald.intevation.org