diff options
Diffstat (limited to 'template/en/default/global')
-rw-r--r-- | template/en/default/global/header.html.tmpl | 8 | ||||
-rw-r--r-- | template/en/default/global/userselect.html.tmpl | 25 |
2 files changed, 12 insertions, 21 deletions
diff --git a/template/en/default/global/header.html.tmpl b/template/en/default/global/header.html.tmpl index 65b96ec84..b05784ebe 100644 --- a/template/en/default/global/header.html.tmpl +++ b/template/en/default/global/header.html.tmpl @@ -43,7 +43,6 @@ [% IF NOT no_yui %] [% SET yui_css = { - autocomplete => 1, calendar => 1, datatable => 1, button => 1, @@ -54,8 +53,7 @@ # if that module is going to be specified in "yui". #%] [% SET yui_deps = { - autocomplete => ['json', 'connection', 'datasource'], - datatable => ['json', 'connection', 'datasource', 'element'], + datatable => ['json', 'connection', 'datasource', 'element'], } %] [%# When using certain YUI modules, we need to process certain @@ -86,8 +84,8 @@ ] %] [% style_urls.import(jquery_css, jq_css_urls) FILTER null %] -[%# Add jQuery cookie support %] -[% jquery.push("cookie") %] +[%# Add our required jQuery plugins %] +[% jquery.push("cookie", "devbridgeAutocomplete") %] [%# We should be able to set the default value of the header variable # to the value of the title variable using the DEFAULT directive, diff --git a/template/en/default/global/userselect.html.tmpl b/template/en/default/global/userselect.html.tmpl index e2210c6f2..67d9f8d48 100644 --- a/template/en/default/global/userselect.html.tmpl +++ b/template/en/default/global/userselect.html.tmpl @@ -71,10 +71,14 @@ [% END %] </select> [% ELSE %] - [% IF feature_enabled('jsonrpc') && Param('ajax_user_autocompletion') && id %] - <div id="[% id FILTER html %]_autocomplete" - [% IF classes %] class="[% classes.join(' ') FILTER html %]" [% END %]> - [% END %] + [% + IF id && feature_enabled('jsonrpc') && Param('ajax_user_autocompletion'); + IF !classes.defined; + classes = []; + END; + classes.push("bz_autocomplete_user"); + END; + %] <input name="[% name FILTER html %]" value="[% value FILTER html %]" @@ -86,17 +90,6 @@ [% IF size %] size="[% size FILTER html %]" [% END %] [% IF id %] id="[% id FILTER html %]" [% END %] [% IF mandatory %] required [% END %] + [% IF multiple %] data-multiple="1" [% END %] > - [% IF feature_enabled('jsonrpc') && Param('ajax_user_autocompletion') && id %] - <div id="[% id FILTER html %]_autocomplete_container"></div> - </div> - <script type="text/javascript"> - if( typeof(YAHOO.bugzilla.userAutocomplete) !== 'undefined' - && YAHOO.bugzilla.userAutocomplete != null){ - YAHOO.bugzilla.userAutocomplete.init( "[% id FILTER js %]", - "[% id FILTER js %]_autocomplete_container" - [% IF multiple %], true[% END%]); - } - </script> - [% END %] [% END %] |