partkeepr

fork of partkeepr
git clone https://git.e1e0.net/partkeepr.git
Log | Files | Refs | Submodules | README | LICENSE

commit 0758f81ce41ba2d0c862b2b78040cf803ea3cd10
parent cac51d706feb15345e1c660fe0d8635b6a42e2e1
Author: felicitus <felicitus@felicitus.org>
Date:   Fri,  6 Jul 2012 00:19:56 +0200

forceSelection doesn't work for async loads; revert to the previous behaviour and don't call setValue() when the id is zero

Diffstat:
Msrc/frontend/js/Components/Widgets/StorageLocationComboBox.js | 7++++++-
1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/frontend/js/Components/Widgets/StorageLocationComboBox.js b/src/frontend/js/Components/Widgets/StorageLocationComboBox.js @@ -4,7 +4,6 @@ Ext.define("PartKeepr.StorageLocationComboBox",{ displayField: 'name', valueField: 'id', queryMode: 'local', - forceSelection: true, triggerAction: 'all', trigger2Cls: Ext.baseCSSPrefix + 'form-reload-trigger', @@ -26,6 +25,12 @@ Ext.define("PartKeepr.StorageLocationComboBox",{ }); this.callParent(); + }, + setValue: function (val) { + if (val == 0) { + return; + } + this.callParent(arguments); } });