work around minLength problem in jquery-ui-autocomplete
This commit is contained in:
parent
24bb9eea92
commit
407daf0bfa
1 changed files with 5 additions and 1 deletions
|
@ -154,6 +154,10 @@ jQuery(document).ready(function() {
|
|||
|
||||
source: function(request, response) {
|
||||
// delegate back to autocomplete, but extract the last term
|
||||
var term = extractLast(request.term);
|
||||
if (term.length < this.options.minLength) {
|
||||
return;
|
||||
}
|
||||
response(
|
||||
/*
|
||||
$.ui.autocomplete.filter(
|
||||
|
@ -162,7 +166,7 @@ jQuery(document).ready(function() {
|
|||
*/
|
||||
$.getJSON(
|
||||
"<?php echo $ajaxUrl; ?>",
|
||||
{ beginsWith: extractLast(request.term) },
|
||||
{ beginsWith: term },
|
||||
response
|
||||
)
|
||||
);
|
||||
|
|
Loading…
Reference in a new issue