#5992 closed bug (duplicate)
autocomplete - not doing ajax request due to backslash or delete key
Reported by: | francesco.savoia | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | |
Component: | ui.autocomplete | Version: | 1.8.4 |
Keywords: | Cc: | [email protected]… | |
Blocked by: | Blocking: |
Description
I'm using autocomplete with ui 1.8.4 and core 1.4.2
The use-case is the following:
with minLenght:1
1) Type a
2) the <ul> with suggested results comes out, that's ok
3) press <backspace> or highlight the text just entered and then press <cancel>
4) Type a
5) Noting happens
I think the problem is what happens at line 4817 of jquery-ui-1.8.4.custom.js
// only search if the value has changed if ( self.term != self.element.val() ) {
1) type a, term == undefined, self.element.val()==a, ok, do the search and set term=a
2) press backspace or delete what is within input, the "if" returns true, the search is invoked but since
''.length == 0
, it does not comply with minLength value, preventing the search and NOT setting term = empty string.
3) type a, term == a, self.element.val == a, the "if" returns false, doing anything.
I think the problem could be solved setting term to the value typed even if the minLenght is not reached.
Change History (3)
comment:1 Changed 12 years ago by
comment:2 Changed 12 years ago by
Component: | ui.core → ui.autocomplete |
---|---|
Resolution: | → duplicate |
Status: | new → closed |
Duplicate of #5922.
You say "I'm using that version of code" but I'm not sure what that means since you also say you're using 1.8.4, which has the bug.
referring to: Ticket #5922
I'm using that version of code, but it DOES NOT work. The problem does still exist.