]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Patch for bug 267494: 'Voter' column should not appear in email preferences if param...
authorjocuri%softhome.net <>
Sat, 20 Nov 2004 20:18:34 +0000 (20:18 +0000)
committerjocuri%softhome.net <>
Sat, 20 Nov 2004 20:18:34 +0000 (20:18 +0000)
template/en/default/account/prefs/email.html.tmpl
template/en/default/filterexceptions.pl

index 5bf4920174705a67972ffd5dddd8bc3026eafe4e..71de881c65327f0015ee85e5f3bd27b6fe323a4f 100644 (file)
@@ -17,6 +17,7 @@
   # Rights Reserved.
   #
   # Contributor(s): Gervase Markham <gerv@gerv.net>
+  #                 Shane H. W. Travis <travis@sedsystems.ca>
   #%]
 
 [%# INTERFACE:
@@ -32,6 +33,7 @@
   #%]
 
 [% useqacontact = Param('useqacontact') %]
+[% usevotes = Param('usevotes') %]
  
 <table>
   [% IF Param('supportwatchers') %]
 
 <table width="100%" border="1">
   <tr>
-    <td colspan="[% useqacontact ? '5' : '4' %]" align="center" width="50%">
+    <td colspan="[% (useqacontact AND usevotes) ? '5' : ((useqacontact OR usevotes) ? '4' : '3') %]" align="center" width="50%">
       <b>When my relationship to this bug is:</b>
     </td>
     <td rowspan="2" width="50%">
     <td align="center" width="10%">
       <b>CC</b>
     </td>
-    <td align="center" width="10%">
-      <b>Voter</b>
-    </td>
+    [% IF usevotes %]
+      <td align="center" width="10%">
+        <b>Voter</b>
+      </td>
+    [% END %]
   </tr>
 
   [% FOREACH reason = [ 
       [% FOREACH role = [ "Reporter", "Owner", "QAcontact", "CClist", "Voter" ] 
        %]
         [% NEXT IF role == "QAcontact" AND NOT useqacontact %]
+        [% NEXT IF role == "Voter" AND NOT usevotes %]
         <td align="center">
           <input type="checkbox" name="email[% role %][% reason.name %]" value="on"
             [% " checked" IF $role.${reason.name} %]>
index 08a021bb298e04060a6975caec665e23eecce2da..4f1f8c66c5cbc5fd126ef30e15956a923d9d7f7b 100644 (file)
 
 'account/prefs/email.html.tmpl' => [
   'watchedusers', # Email
-  'useqacontact ? \'5\' : \'4\'',
+  '(useqacontact AND usevotes) ? \'5\' : ((useqacontact OR usevotes) ? \'4\' : \'3\')',
   'role',
   'reason.name',
   'reason.description',