summaryrefslogtreecommitdiffstats
path: root/template/en/default/email
diff options
context:
space:
mode:
authorMax Kanat-Alexander <mkanat@bugzilla.org>2010-02-16 00:22:55 +0100
committerMax Kanat-Alexander <mkanat@bugzilla.org>2010-02-16 00:22:55 +0100
commit120b63d507a3316666b25494bc890a024948aef8 (patch)
tree0a96e60d6316cc8471b066def8b1e1273f38e4ab /template/en/default/email
parent7802dbcf7bedcc09e5f1052ceb1ba82347a124b7 (diff)
downloadbugzilla-120b63d507a3316666b25494bc890a024948aef8.tar.gz
bugzilla-120b63d507a3316666b25494bc890a024948aef8.tar.xz
Bug 372979: Make voting into an extension
r=mkanat, a=mkanat, a=LpSolit
Diffstat (limited to 'template/en/default/email')
-rw-r--r--template/en/default/email/newchangedmail.txt.tmpl37
-rw-r--r--template/en/default/email/votes-removed.txt.tmpl55
2 files changed, 9 insertions, 83 deletions
diff --git a/template/en/default/email/newchangedmail.txt.tmpl b/template/en/default/email/newchangedmail.txt.tmpl
index 1bcc2e40d..7d30b890d 100644
--- a/template/en/default/email/newchangedmail.txt.tmpl
+++ b/template/en/default/email/newchangedmail.txt.tmpl
@@ -19,6 +19,8 @@
#%]
[% PROCESS "global/variables.none.tmpl" %]
+[% PROCESS "global/reason-descs.none.tmpl" %]
+
From: [% Param('mailfrom') %]
To: [% to_user.email %]
Subject: [[% terms.Bug %] [%+ bugid %]] [% 'New: ' IF isnew %][%+ summary %]
@@ -56,33 +58,12 @@ X-Bugzilla-Changed-Fields: [% changedfields %]
-- [%# Protect the trailing space of the signature marker %]
Configure [% terms.bug %]mail: [% urlbase %]userprefs.cgi?tab=email
------- You are receiving this mail because: -------
-[% FOREACH relationship = reasons %]
- [% SWITCH relationship %]
- [% CASE constants.REL_ASSIGNEE %]
-You are the assignee for the [% terms.bug %].
- [% CASE constants.REL_REPORTER %]
-You reported the [% terms.bug %].
- [% CASE constants.REL_QA %]
-You are the QA contact for the [% terms.bug %].
- [% CASE constants.REL_CC %]
-You are on the CC list for the [% terms.bug %].
- [% CASE constants.REL_VOTER %]
-You are a voter for the [% terms.bug %].
- [% CASE constants.REL_GLOBAL_WATCHER %]
-You are watching all [% terms.bug %] changes.
- [% END %]
+[% SET reason_lines = [] %]
+[% FOREACH reason = reasons %]
+ [% reason_lines.push(reason_descs.$reason) IF reason_descs.$reason %]
[% END %]
-[% FOREACH relationship = reasons_watch %]
- [% SWITCH relationship %]
- [% CASE constants.REL_ASSIGNEE %]
-You are watching the assignee of the [% terms.bug %].
- [% CASE constants.REL_REPORTER %]
-You are watching the reporter.
- [% CASE constants.REL_QA %]
-You are watching the QA contact of the [% terms.bug %].
- [% CASE constants.REL_CC %]
-You are watching someone on the CC list of the [% terms.bug %].
- [% CASE constants.REL_VOTER %]
-You are watching a voter for the [% terms.bug %].
- [% END %]
+[% FOREACH reason = reasons_watch %]
+ [% reason_lines.push(watch_reason_descs.$reason)
+ IF watch_reason_descs.$reason %]
[% END %]
+[%+ reason_lines.join("\n") %]
diff --git a/template/en/default/email/votes-removed.txt.tmpl b/template/en/default/email/votes-removed.txt.tmpl
deleted file mode 100644
index bfb37c90d..000000000
--- a/template/en/default/email/votes-removed.txt.tmpl
+++ /dev/null
@@ -1,55 +0,0 @@
-[%# The contents of this file are subject to the Mozilla Public
- # License Version 1.1 (the "License"); you may not use this file
- # except in compliance with the License. You may obtain a copy of
- # the License at http://www.mozilla.org/MPL/
- #
- # Software distributed under the License is distributed on an "AS
- # IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- # implied. See the License for the specific language governing
- # rights and limitations under the License.
- #
- # The Original Code is the Bugzilla Bug Tracking System.
- #
- # The Initial Developer of the Original Code is Netscape Communications
- # Corporation. Portions created by Netscape are
- # Copyright (C) 1998 Netscape Communications Corporation. All
- # Rights Reserved.
- #
- # Contributor(s): Emmanuel Seyman <eseyman@linagora.com>
- #%]
-
-[% PROCESS global/variables.none.tmpl %]
-
-From: [% Param('mailfrom') %]
-To: [% to %]
-Subject: [% terms.Bug %] [%+ bugid %] Some or all of your votes have been removed.
-X-Bugzilla-Type: voteremoved
-
-Some or all of your votes have been removed from [% terms.bug %] [%+ bugid %].
-
-You had [% votesold FILTER html %] [%+ IF votesold == 1 %]vote[% ELSE %]votes[% END
-%] on this [% terms.bug %], but [% votesremoved FILTER html %] have been removed.
-
-[% IF votesnew %]
-You still have [% votesnew FILTER html %] [%+ IF votesnew == 1 %]vote[% ELSE %]votes[% END %] on this [% terms.bug %].
-[% ELSE %]
-You have no more votes remaining on this [% terms.bug %].
-[% END %]
-
-Reason:
-[% IF reason == "votes_bug_moved" %]
- This [% terms.bug %] has been moved to a different product.
-
-[% ELSIF reason == "votes_too_many_per_bug" %]
- The rules for voting on this product has changed;
- you had too many votes for a single [% terms.bug %].
-
-[% ELSIF reason == "votes_too_many_per_user" %]
- The rules for voting on this product has changed; you had
- too many total votes, so all votes have been removed.
-[% END %]
-
-
-
-[% urlbase %]show_bug.cgi?id=[% bugid %]
-