summaryrefslogtreecommitdiffstats
path: root/template
diff options
context:
space:
mode:
authorByron Jones <glob@mozilla.com>2015-07-27 06:19:17 +0200
committerByron Jones <glob@mozilla.com>2015-07-27 06:19:17 +0200
commita8ef3e105b01d4a7f765edbe53b7af53ed179020 (patch)
treecf9340948a7944b6d0755f2de514d7c3a4936882 /template
parent1e3288184f015700e109ead8e21c1383152e340b (diff)
downloadbugzilla-a8ef3e105b01d4a7f765edbe53b7af53ed179020.tar.gz
bugzilla-a8ef3e105b01d4a7f765edbe53b7af53ed179020.tar.xz
Bug 1186788 - disabling an account should always disable bugmail
Diffstat (limited to 'template')
-rw-r--r--template/en/default/admin/users/edit.html.tmpl16
-rw-r--r--template/en/default/admin/users/userdata.html.tmpl20
2 files changed, 27 insertions, 9 deletions
diff --git a/template/en/default/admin/users/edit.html.tmpl b/template/en/default/admin/users/edit.html.tmpl
index 8eced20f7..a5ab5cf03 100644
--- a/template/en/default/admin/users/edit.html.tmpl
+++ b/template/en/default/admin/users/edit.html.tmpl
@@ -26,9 +26,25 @@
[% title = BLOCK %]Edit user [% otheruser.identity FILTER html %][% END %]
+[% js = BLOCK %]
+$(function() {
+ $('#disabledtext')
+ .keyup(function() {
+ if ($(this).val().trim() !== '') {
+ $('#disable_mail').prop('checked', true).prop('disabled', true);
+ }
+ else {
+ $('#disable_mail').prop('disabled', false);
+ }
+ })
+ .keyup();
+});
+[% END %]
+
[% PROCESS global/header.html.tmpl
title = title
message = message
+ javascript = js
style_urls = ['skins/standard/admin.css', 'skins/standard/editusers.css']
doc_section = "useradmin.html#modifyusers"
%]
diff --git a/template/en/default/admin/users/userdata.html.tmpl b/template/en/default/admin/users/userdata.html.tmpl
index f3f0e5aa9..16d720a4a 100644
--- a/template/en/default/admin/users/userdata.html.tmpl
+++ b/template/en/default/admin/users/userdata.html.tmpl
@@ -25,10 +25,10 @@
<td>
[% IF editusers %]
<input size="64" maxlength="255" name="login"
- id="login" value="[% otheruser.login FILTER html %]" />
+ id="login" value="[% otheruser.login FILTER html %]">
[% IF editform %]
[% IF !otheruser.in_group('bz_sudo_protect') %]
- <br />
+ <br>
<a href="relogin.cgi?action=prepare-sudo&amp;target_login=
[%- otheruser.login FILTER uri %]">Impersonate this user</a>
[% END %]
@@ -57,7 +57,7 @@
[% IF editusers %]
<input size="64" maxlength="255" name="name"
autocomplete="off"
- id="name" value="[% otheruser.name FILTER html %]" />
+ id="name" value="[% otheruser.name FILTER html %]">
[% ELSE %]
[% otheruser.name FILTER html %]
[% END %]
@@ -75,8 +75,8 @@
<th><label for="password">Password:</label></th>
<td>
<input type="password" size="16" name="password" id="password"
- value="" autocomplete="off" />
- [% IF editform %]<br />
+ value="" autocomplete="off">
+ [% IF editform %]<br>
(Enter new password to change.)
[% END %]
</td>
@@ -85,10 +85,12 @@
<tr>
<th><label for="disable_mail">[% terms.Bug %]mail Disabled:</label></th>
<td>
- <input type="checkbox" name="disable_mail" id="disable_mail" value="1"
- [% IF otheruser.email_disabled %] checked="checked" [% END %] />
- (This affects [% terms.bug %]mail and whinemail, not password-reset or other
- non-[% terms.bug %]-related emails)
+ <input type="checkbox" name="disable_mail" id="disable_mail" value="1"
+ [% IF otheruser.email_disabled %] checked="checked" [% END %]>
+ <label for="disable_mail">
+ (This affects [% terms.bug %]mail and whinemail, not password-reset or other
+ non-[% terms.bug %]-related emails)
+ </label>
</td>
</tr>
<tr>