comparison app/view/widget/Testdatensatz.js @ 740:2e8da590ea0c

made Comboboces editable and filterable for; Messungenform: Messstelle,Datenbasis,Betriebsarts,Testdatensatz,Preobenart,Netzbetreiber Messungform: Messmethode Messwertegrid: Messgroesse,Messeinheit
author Dustin Demuth <dustin@intevation.de>
date Mon, 20 Apr 2015 16:07:40 +0200
parents 8a156a7fbe67
children
comparison
equal deleted inserted replaced
739:efb1369a8cac 740:2e8da590ea0c
5 * and comes with ABSOLUTELY NO WARRANTY! Check out 5 * and comes with ABSOLUTELY NO WARRANTY! Check out
6 * the documentation coming with IMIS-Labordaten-Application for details. 6 * the documentation coming with IMIS-Labordaten-Application for details.
7 */ 7 */
8 8
9 9
10 var testdatensatzStore = Ext.create('Ext.data.Store', {
11 fields: ['testdatensatzId', 'testdatensatz'],
12 storeId: 'testdatensatzStore',
13 data: [{
14 'testdatensatzId': true,
15 'testdatensatz': 'Ja'
16 }, {
17 'testdatensatzId': false,
18 'testdatensatz': 'Nein'
19 }]
20 });
10 21
11 /** 22 /**
12 * Combobox for Testdatensatz. 23 * Combobox for Testdatensatz.
13 * This widget is also used a generic "Ja/Nein" combobox. 24 * This widget is also used a generic "Ja/Nein" combobox.
14 */ 25 */
15 Ext.define('Lada.view.widget.Testdatensatz', { 26 Ext.define('Lada.view.widget.Testdatensatz', {
16 extend: 'Lada.view.widget.base.ComboBox', 27 extend: 'Lada.view.widget.base.ComboBox',
17 alias: 'widget.testdatensatz', 28 alias: 'widget.testdatensatz',
29 store: 'testdatensatzStore',
18 queryMode: 'local', 30 queryMode: 'local',
31 triggerAction: 'all',
32 typeAhead: false,
33 minChars: 0,
34
19 displayField: 'testdatensatz', 35 displayField: 'testdatensatz',
20 valueField: 'testdatensatzId', 36 valueField: 'testdatensatzId',
21 emptyText: 'Testdatensatz?', 37 emptyText: 'Testdatensatz?',
22 38
23 initComponent: function() { 39 initComponent: function() {
24 this.store = Ext.create('Ext.data.Store', { 40 this.store = Ext.data.StoreManager.get('testdatensatzStore')
25 fields: ['testdatensatzId', 'testdatensatz'], 41 this.store.clearFilter();
26 data: [{
27 'testdatensatzId': true,
28 'testdatensatz': 'Ja'
29 }, {
30 'testdatensatzId': false,
31 'testdatensatz': 'Nein'
32 }]
33 });
34 this.callParent(arguments); 42 this.callParent(arguments);
35 } 43 }
36 }); 44 });

http://lada.wald.intevation.org