PDA

View Full Version : [OPEN] Invalid entry in combobox keeps a valid value



fecund
19 Apr 2007, 1:22 PM
If I have a combo box (built with "transform" from an existing Select) with these choices:

+---------------+
|(Pick one...) |
+---------------+
| A thing |
| Choose me! |
| Last |
+---------------+


And then I pick one:

+---------------+
| Last |
+---------------+
| Last |
+---------------+


And then I type something which invalidates my choice:

+---------------+
| Last & Least |
+---------------+
+---------------+


The combobox keeps the value for "Last" and sends it back on a submit.

This seems like a bug, if what's typed in the combobox doesn't match anything, shouldn't the value should be empty?

jack.slocum
19 Apr 2007, 3:49 PM
What does your config look like?

fecund
20 Apr 2007, 10:39 AM
var c = new Ext.form.ComboBox({
triggerAction: 'all',
transform:id, // id='id_firm'
emptyText:'Select one, or type new...',
width:230
});