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) {
|
source: function(request, response) {
|
||||||
// delegate back to autocomplete, but extract the last term
|
// delegate back to autocomplete, but extract the last term
|
||||||
|
var term = extractLast(request.term);
|
||||||
|
if (term.length < this.options.minLength) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
response(
|
response(
|
||||||
/*
|
/*
|
||||||
$.ui.autocomplete.filter(
|
$.ui.autocomplete.filter(
|
||||||
|
@ -162,7 +166,7 @@ jQuery(document).ready(function() {
|
||||||
*/
|
*/
|
||||||
$.getJSON(
|
$.getJSON(
|
||||||
"<?php echo $ajaxUrl; ?>",
|
"<?php echo $ajaxUrl; ?>",
|
||||||
{ beginsWith: extractLast(request.term) },
|
{ beginsWith: term },
|
||||||
response
|
response
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in a new issue