raimund@548: /* Copyright (C) 2013 by Bundesamt fuer Strahlenschutz
raimund@548:  * Software engineering by Intevation GmbH
raimund@548:  *
raimund@548:  * This file is Free Software under the GNU GPL (v>=3)
raimund@548:  * and comes with ABSOLUTELY NO WARRANTY! Check out
raimund@548:  * the documentation coming with IMIS-Labordaten-Application for details.
raimund@548:  */
raimund@548: 
raimund@548: /**
raimund@548:  * Combobox for Messmethode
raimund@548:  */
raimund@548: Ext.define('Lada.view.widget.Messmethode', {
raimund@548:     extend: 'Lada.view.widget.base.ComboBox',
raimund@548:     alias: 'widget.messmethode',
raimund@548:     store: 'Messmethoden',
raimund@548:     displayField: 'display',
raimund@548:     valueField: 'id',
raimund@548:     emptyText: 'Wählen Sie eine Messmethode',
raimund@548:     // Enable filtering of comboboxes
raimund@548:     queryMode: 'local',
raimund@548:     triggerAction: 'all',
raimund@548:     typeAhead: true,
raimund@548:     minChars: 0,
dustin@611:     layout: 'hbox',
dustin@708: 
raimund@548:     initComponent: function() {
raimund@548:         this.store = Ext.data.StoreManager.get('messmethoden');
raimund@548:         if (!this.store) {
raimund@548:             this.store = Ext.create('Lada.store.Messmethoden');
raimund@548:         }
dustin@740:         else {
dustin@740:             this.store.clearFilter();
dustin@740:         }
raimund@548:         this.callParent(arguments);
raimund@548:     }
raimund@548: });