summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Bugzilla/Config/UserMatch.pm6
-rw-r--r--Bugzilla/Mailer.pm2
-rw-r--r--docs/en/xml/administration.xml7
-rw-r--r--template/en/default/admin/params/usermatch.html.tmpl3
-rw-r--r--template/en/default/global/userselect.html.tmpl4
5 files changed, 19 insertions, 3 deletions
diff --git a/Bugzilla/Config/UserMatch.pm b/Bugzilla/Config/UserMatch.pm
index f97cfeab2..38d2cb05b 100644
--- a/Bugzilla/Config/UserMatch.pm
+++ b/Bugzilla/Config/UserMatch.pm
@@ -47,6 +47,12 @@ sub get_param_list {
},
{
+ name => 'ajax_user_autocompletion',
+ type => 'b',
+ default => '1',
+ },
+
+ {
name => 'maxusermatches',
type => 't',
default => '1000',
diff --git a/Bugzilla/Mailer.pm b/Bugzilla/Mailer.pm
index 699467ed8..f8d5e9556 100644
--- a/Bugzilla/Mailer.pm
+++ b/Bugzilla/Mailer.pm
@@ -171,6 +171,8 @@ sub MessageToMTA {
Bugzilla::Hook::process('mailer_before_send',
{ email => $email, mailer_args => \@args });
+ return if $email->header('to') eq '';
+
if ($method eq "Test") {
my $filename = bz_locations()->{'datadir'} . '/mailer.testfile';
open TESTFILE, '>>', $filename;
diff --git a/docs/en/xml/administration.xml b/docs/en/xml/administration.xml
index 3796c8caf..82d986791 100644
--- a/docs/en/xml/administration.xml
+++ b/docs/en/xml/administration.xml
@@ -864,7 +864,12 @@
contains parameters for how user names can be queried and matched
when entered.
</para>
-
+ <para>
+ Another setting called 'ajax_user_autocompletion' enables certain
+ user fields to display a list of matched user names as a drop down after typing
+ a few characters. Note that it is recommended to use mod_perl when
+ enabling 'ajax_user_autocompletion'.
+ </para>
</section>
</section>
diff --git a/template/en/default/admin/params/usermatch.html.tmpl b/template/en/default/admin/params/usermatch.html.tmpl
index 54f150900..d574edca7 100644
--- a/template/en/default/admin/params/usermatch.html.tmpl
+++ b/template/en/default/admin/params/usermatch.html.tmpl
@@ -29,6 +29,9 @@
"needs to be selected. This option should not be enabled on " _
"sites where there are a large number of users.",
+ ajax_user_autocompletion => "If this option is set, typing characters in a certain user " _
+ "fields will display a list of matches that can be selected from.",
+
maxusermatches => "Search for no more than this many matches.<br> " _
"If set to '1', no users will be displayed on ambiguous matches. " _
"This is useful for user privacy purposes.<br> " _
diff --git a/template/en/default/global/userselect.html.tmpl b/template/en/default/global/userselect.html.tmpl
index 600b21c13..1d0395043 100644
--- a/template/en/default/global/userselect.html.tmpl
+++ b/template/en/default/global/userselect.html.tmpl
@@ -79,7 +79,7 @@
[% END %]
</select>
[% ELSE %]
- [% IF id && feature_enabled('jsonrpc') %]
+ [% IF feature_enabled('jsonrpc') && Param('ajax_user_autocompletion') && id %]
<div id="[% id FILTER html %]_autocomplete"
[% IF classes %] class="[% classes.join(' ') FILTER html %]" [% END %]>
[% END %]
@@ -94,7 +94,7 @@
[% IF size %] size="[% size FILTER html %]" [% END %]
[% IF id %] id="[% id FILTER html %]" [% END %]
>
- [% IF id && feature_enabled('jsonrpc') %]
+ [% IF feature_enabled('jsonrpc') && Param('ajax_user_autocompletion') && id %]
<div id="[% id FILTER html %]_autocomplete_container"></div>
</div>
<script type="text/javascript">