]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Patch for bug 257765: Make replies to private comments private by default; patch...
authorjocuri%softhome.net <>
Sun, 10 Oct 2004 03:39:20 +0000 (03:39 +0000)
committerjocuri%softhome.net <>
Sun, 10 Oct 2004 03:39:20 +0000 (03:39 +0000)
template/en/default/bug/comments.html.tmpl
template/en/default/bug/edit.html.tmpl

index a2ef46a8af3d1be5272c6ac6930e0350a13dba61..160d828108b0fd5455dcea3e3ac70ca27095405d 100644 (file)
@@ -67,6 +67,7 @@
                  value="[% comment.isprivate %]">
           <input type="hidden" name="when-[% count %]" value="[% comment.when %]">
           <input type="checkbox" name="isprivate-[% count %]" value="1"
+                 id="isprivate-[% count %]"
           [% " checked=\"checked\"" IF comment.isprivate %]> Private
         </i>
       [% END %]
index f775c51354cfe1aaef2559a24d269b493bdc8cbd..60ee703107c0edd7a560569b84d59b2f9343cf8a 100644 (file)
 
     replytext = "(In reply to comment #" + id + ")\n" + replytext + "\n";
 
+    [% IF Param("insidergroup") && UserInGroup(Param("insidergroup")) %]
+      if (document.getElementById('isprivate-'+id).checked) {
+          document.getElementById('newcommentprivacy').checked = 'checked';
+      }
+    [% END %]
+
     /* <textarea id="comment"> */
     var textarea = document.getElementById('comment');
     textarea.value += replytext;
   <br>
   <b>Additional <u>C</u>omments:</b>
   [% IF Param("insidergroup") && UserInGroup(Param("insidergroup")) %]
-    <input type="checkbox" name="commentprivacy" value="1"> Private
+    <input type="checkbox" name="commentprivacy" value="1"
+           id="newcommentprivacy"> Private
   [% END %]
   <br>
   <a name="add_comment"></a>