From 9c0a26d3a5a35788694f5f284c69b995a3298c86 Mon Sep 17 00:00:00 2001
From: "gerv%gerv.net" <>
Date: Tue, 20 Aug 2002 04:17:18 +0000
Subject: Bug 143286 - Add support for Insiders, Private comments, Private
Attachments. Patch by bugreport@peshkin.net; r=gerv.
---
template/en/default/attachment/create.html.tmpl | 17 +++++++++++--
template/en/default/attachment/edit.html.tmpl | 3 +++
template/en/default/attachment/list.html.tmpl | 6 +++--
template/en/default/bug/comments.html.tmpl | 32 ++++++++++++++++++-------
template/en/default/bug/edit.html.tmpl | 7 +++++-
template/en/default/bug/show-multiple.html.tmpl | 2 +-
6 files changed, 52 insertions(+), 15 deletions(-)
(limited to 'template/en')
diff --git a/template/en/default/attachment/create.html.tmpl b/template/en/default/attachment/create.html.tmpl
index a80708ee3..1c00146e5 100644
--- a/template/en/default/attachment/create.html.tmpl
+++ b/template/en/default/attachment/create.html.tmpl
@@ -94,15 +94,28 @@
onchange="if (this.value) this.form.contenttypemethod[2].checked = true;">
+ [% IF (Param("insidergroup") && UserInGroup(Param("insidergroup"))) %]
+
+ Privacy: |
+
+ If the attachment is private, check the box below.
+
+
+ |
+
+ [% END %]
Obsoletes: |
(optional) Check each existing attachment made obsolete by your new attachment.
[% IF attachments.size %]
[% FOREACH attachment = attachments %]
-
- [% attachment.id %]: [% attachment.description FILTER html %]
+ [% attachment.id %]: [% attachment.description FILTER html %]
+ [% END %]
[% END %]
[% ELSE %]
[no attachments can be made obsolete]
diff --git a/template/en/default/attachment/edit.html.tmpl b/template/en/default/attachment/edit.html.tmpl
index 5d01d2898..c9bc7c1cd 100644
--- a/template/en/default/attachment/edit.html.tmpl
+++ b/template/en/default/attachment/edit.html.tmpl
@@ -163,6 +163,9 @@
+ [% IF (Param("insidergroup") && UserInGroup(Param("insidergroup"))) %]
+ private
+ [% END %]
[% IF statusdefs.size %]
Status:
diff --git a/template/en/default/attachment/list.html.tmpl b/template/en/default/attachment/list.html.tmpl
index bc25c5721..e7aa8b0ef 100644
--- a/template/en/default/attachment/list.html.tmpl
+++ b/template/en/default/attachment/list.html.tmpl
@@ -28,9 +28,10 @@
| Status |
Actions |
-
+ [% canseeprivate = !Param("insidergroup") || UserInGroup(Param("insidergroup")) %]
[% FOREACH attachment = attachments %]
-
+ [% IF !attachment.isprivate || canseeprivate %]
+
[% IF attachment.isobsolete %]
[% attachment.description FILTER html %]
@@ -67,6 +68,7 @@
[% END %]
|
+ [% END %]
[% END %]
diff --git a/template/en/default/bug/comments.html.tmpl b/template/en/default/bug/comments.html.tmpl
index f1f8e762e..7a8ae73db 100644
--- a/template/en/default/bug/comments.html.tmpl
+++ b/template/en/default/bug/comments.html.tmpl
@@ -19,8 +19,9 @@
# Contributor(s): Gervase Markham
#%]
-[% DEFAULT start_at = 0 %]
+[% DEFAULT start_at = 0 mode = "show" %]
[% count = 0 %]
+[% isinsider = Param("insidergroup") && UserInGroup(Param("insidergroup")) %]
[% FOREACH comment = comments %]
[% IF count >= start_at %]
[% PROCESS a_comment %]
@@ -35,14 +36,25 @@
[%############################################################################%]
[% BLOCK a_comment %]
- [% IF count > 0 %]
-
- ------- Additional Comment
- #[% count %] From
- [% comment.name FILTER html %]
- [%+ comment.time %] -------
-
- [% END %]
+ [% IF NOT comment.isprivate || isinsider %]
+
+ [% IF count > 0 %]
+
+
------- Additional Comment
+ #[% count %] From
+ [% comment.name FILTER html %]
+ [%+ comment.time %] -------
+
+ [% END %]
+ [% IF mode == "edit" && isinsider %]
+
+
+
+ Private
+
+ [% END %]
[%# Don't indent the
block, since then the spaces are displayed in the
# generated HTML
@@ -50,4 +62,6 @@
[%- quoteUrls(comment.body) -%]
+
+ [% END %]
[% END %]
diff --git a/template/en/default/bug/edit.html.tmpl b/template/en/default/bug/edit.html.tmpl
index 502952ef2..9cf33b8b5 100644
--- a/template/en/default/bug/edit.html.tmpl
+++ b/template/en/default/bug/edit.html.tmpl
@@ -28,6 +28,7 @@
h2 = filtered_desc
h3 = "Last modified: $bug.calc_disp_date"
header_html = navigation_links
+ style_urls = [ "css/edit_bug.css" ]
%]
[% END %]
@@ -310,6 +311,9 @@
Additional Comments:
+ [% IF Param("insidergroup") && UserInGroup(Param("insidergroup")) %]
+ Private
+ [% END %]
@@ -482,7 +486,6 @@
value="[% Param("move-button-text") %]">
[% END %]
-
[%# *** Additional Comments *** %]
@@ -502,8 +505,10 @@
[% PROCESS bug/comments.html.tmpl
comments = bug.comments
+ mode = "edit"
%]
+
[% PROCESS bug/navigate.html.tmpl %]
diff --git a/template/en/default/bug/show-multiple.html.tmpl b/template/en/default/bug/show-multiple.html.tmpl
index 7c3e7407f..0c089e9c5 100644
--- a/template/en/default/bug/show-multiple.html.tmpl
+++ b/template/en/default/bug/show-multiple.html.tmpl
@@ -22,8 +22,8 @@
[% PROCESS global/header.html.tmpl
title = "Full Text Bug Listing"
+ style_urls = [ "css/show_multiple.css" ]
%]
-
[% IF bugs.first %]
[% FOREACH bug = bugs %]
[% PROCESS bug_display %]
--
cgit v1.2.3-24-g4f1b