diff options
author | Max Kanat-Alexander <mkanat@bugzilla.org> | 2010-08-01 17:52:17 -0700 |
---|---|---|
committer | Max Kanat-Alexander <mkanat@bugzilla.org> | 2010-08-01 17:52:17 -0700 |
commit | 3cfa98677f31d4a6660c330fa9ec0d5206fb3565 (patch) | |
tree | 494c86d5ba256aa761a660bdf41d0051671822a8 /js | |
parent | Bug 583645: Make $dbh->quote always detaint its output, even on DBDs that (diff) | |
download | bugzilla-3cfa98677f31d4a6660c330fa9ec0d5206fb3565.tar.gz bugzilla-3cfa98677f31d4a6660c330fa9ec0d5206fb3565.tar.bz2 bugzilla-3cfa98677f31d4a6660c330fa9ec0d5206fb3565.zip |
Bug 578572: Make the user autocomplete and keyword autocomplete behave
similarly, and fix a race condition in user autocomplete where sometimes
an older result would appear after a newer result, overriding the newer
result.
r=pyrzak, a=mkanat
Diffstat (limited to 'js')
-rw-r--r-- | js/field.js | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/js/field.js b/js/field.js index d2e800b90..3653d2130 100644 --- a/js/field.js +++ b/js/field.js @@ -684,14 +684,13 @@ YAHOO.bugzilla.userAutocomplete = { }, init_ds : function(){ this.dataSource = new YAHOO.util.XHRDataSource("jsonrpc.cgi"); + this.dataSource.connTimeout = 30000; this.dataSource.connMethodPost = true; + this.dataSource.connXhrMode = "cancelStaleRequests"; + this.dataSource.maxCacheEntries = 5; this.dataSource.responseSchema = { resultsList : "result.users", metaFields : { error: "error", jsonRpcId: "id"}, - fields : [ - { key : "email" }, - { key : "real_name"} - ] }; }, init : function( field, container, multiple ) { @@ -701,6 +700,7 @@ YAHOO.bugzilla.userAutocomplete = { var userAutoComp = new YAHOO.widget.AutoComplete( field, container, this.dataSource ); // other stuff we might want to do with the autocomplete goes here + userAutoComp.maxResultsDisplayed = BUGZILLA.param.maxusermatches; userAutoComp.generateRequest = this.generateRequest; userAutoComp.formatResult = this.resultListFormat; userAutoComp.doBeforeLoadData = this.debug_helper; |