]> 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:51 +0000 (03:39 +0000)
committerjocuri%softhome.net <>
Sun, 10 Oct 2004 03:39:51 +0000 (03:39 +0000)
template/en/default/bug/comments.html.tmpl
template/en/default/bug/edit.html.tmpl

index 2015d3abd4df2a69a33180af939629976783a055..2f82b46dc735eaab20478a9e6eff928db0f0f68f 100644 (file)
@@ -68,6 +68,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 7e259283a201e847e9e63239da27ed895f0a530b..2585c6c924e19117a10e89bebc71c1477388251d 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>