From 882dcc873146d665f2d1257b89e588ae6e6356f0 Mon Sep 17 00:00:00 2001 From: "gerv%gerv.net" <> Date: Wed, 30 Mar 2005 05:42:53 +0000 Subject: Bug 73665 - migrate email preferences to their own table, and rearchitect email internals. Patch by gerv; r=jake, a=justdave. --- template/en/default/account/prefs/email.html.tmpl | 319 +++++++++++++--------- 1 file changed, 185 insertions(+), 134 deletions(-) (limited to 'template/en/default/account') diff --git a/template/en/default/account/prefs/email.html.tmpl b/template/en/default/account/prefs/email.html.tmpl index ba07fb155..f712bd8fa 100644 --- a/template/en/default/account/prefs/email.html.tmpl +++ b/template/en/default/account/prefs/email.html.tmpl @@ -40,56 +40,32 @@ [% useqacontact = Param('useqacontact') %] [% usevotes = Param('usevotes') %] - - [% IF Param('supportwatchers') %] - - - - - - - +

+ If you don't like getting a notification for "trivial" + changes to [% terms.bugs %], you can use the settings below to + filter some or all notifications. +

- - - - - - - - - - [% END %] +
@@ -103,129 +79,204 @@ - - - -
-
-
- If you want to help cover for someone when they're on vacation, or if - you need to do the QA related to all of their [% terms.bugs %], you can tell - [%+ terms.Bugzilla %] to send mail related to their [% terms.bugs %] to you, too. List the - email addresses of any accounts you wish to watch here, separated by - commas. -
Users to watch: - -
Users watching you: - [% IF watchers.size %] - [% FOREACH watcher = watchers %] - [% watcher FILTER html %]
- [% END %] - [% ELSE %] - Nobody is currently watching your account. - [% END %] -
- - -
-
- - + [% prefname = "email-$constants.REL_ANY-$constants.EVT_FLAG_REQUESTED" %] + +
- - + [% prefname = "email-$constants.REL_ANY-$constants.EVT_REQUESTED_FLAG" %] + +
- -
Field/recipient specific options:

+[% events = [ + { id = constants.EVT_ADDED_REMOVED, + description = "I'm added to or removed from this capacity" }, + { id = constants.EVT_OPENED_CLOSED, + description = "The $terms.bug is resolved or reopened" }, + { id = constants.EVT_PROJ_MANAGEMENT, + description = "The priority, status, severity, or milestone changes" }, + { id = constants.EVT_COMMENT, + description = "New comments are added" }, + { id = constants.EVT_ATTACHMENT, + description = "New attachments are added" }, + { id = constants.EVT_ATTACHMENT_DATA, + description = "Some attachment data changes" }, + { id = constants.EVT_KEYWORD, + description = "The keywords field changes" }, + { id = constants.EVT_CC, + description = "The CC field changes" }, + { id = constants.EVT_OTHER, + description = "Any field not mentioned above changes" }, +] %] + +[% neg_events = [ + { id = constants.EVT_UNCONFIRMED, + description = "The $terms.bug is in the UNCONFIRMED state" }, + { id = constants.EVT_CHANGED_BY_ME, + description = "The change was made by me" }, +] %] + +[% relationships = [ + { id = constants.REL_ASSIGNEE, + description = "Assignee" }, + { id = constants.REL_QA, + description = "QA Contact" }, + { id = constants.REL_REPORTER, + description = "Reporter" }, + { id = constants.REL_CC, + description = "CCed" }, + { id = constants.REL_VOTER, + description = "Voter" }, +] %] - - - - - [% IF useqacontact %] - + [% FOREACH relationship = relationships %] + [% NEXT IF (relationship.id == constants.REL_QA AND NOT useqacontact) OR + (relationship.id == constants.REL_VOTER AND NOT usevotes) %] + [% END %] - - [% IF usevotes %] - + + [% FOREACH event = events %] + + [% FOREACH relationship = relationships %] + [% NEXT IF (relationship.id == constants.REL_QA AND NOT useqacontact) OR + (relationship.id == constants.REL_VOTER AND NOT usevotes) %] + + [% END %] + - [% END %] + + [% END %] + + + + -[% bugLabelLower = BLOCK %] -[% terms.bug %] -[% END %] - - [% FOREACH reason = [ - { name = 'Removeme', - description = "I'm added to or removed from this capacity" }, - { name = 'Comments', - description = "New Comments are added" }, - { name = 'Attachments', - description = "New Attachments are added" }, - { name = 'Status', - description = "Priority, status, severity, and/or milestone changes" }, - { name = 'Resolved', - description = "The ${bugLabelLower} is resolved or verified" }, - { name = 'Keywords', - description = "Keywords field changes" }, - { name = 'CC', - description = "CC field changes" }, - { name = 'Other', - description = "Any field not mentioned above changes" }, - { name = 'Unconfirmed', - description = "The ${bugLabelLower} is in the unconfirmed state" }, - ] %] + [% FOREACH event = neg_events %] - [% FOREACH role = [ "Reporter", "Owner", "QAcontact", "CClist", "Voter" ] - %] - [% NEXT IF role == "QAcontact" AND NOT useqacontact %] - [% NEXT IF role == "Voter" AND NOT usevotes %] - [% END %] [% END %] +
+ When my relationship to this [% terms.bug %] is: + I want to receive mail when:
- Reporter - - Assignee - - QA Contact - + [% relationship.description FILTER html %] + - CC - - Voter +
+ + + [% event.description FILTER html %]
+   + + but not when (overrides above): +
- + [% FOREACH relationship = relationships %] + [% NEXT IF (relationship.id == constants.REL_QA AND NOT useqacontact) OR + (relationship.id == constants.REL_VOTER AND NOT usevotes) %] + - [% reason.description %] + [% event.description FILTER html %]
+[%# Add hidden form fields for fields not used %] +[% FOREACH event = events %] + [% FOREACH relationship = relationships %] + [% IF (relationship.id == constants.REL_QA AND NOT useqacontact) OR + (relationship.id == constants.REL_VOTER AND NOT usevotes) %] + + [% END %] + [% END %] +[% END %] + +[% FOREACH event = neg_events %] + [% FOREACH relationship = relationships %] + [% IF (relationship.id == constants.REL_QA AND NOT useqacontact) OR + (relationship.id == constants.REL_VOTER AND NOT usevotes) %] + + [% END %] + [% END %] +[% END %] + +[% IF Param('supportwatchers') %] +
+User Watching + +

+If you watch a user, it is as if you are standing in their shoes for the +purposes of getting email. Email is sent or not according to your +preferences for their relationship to the [% terms.bug %] +(e.g. Assignee). You are watching anyone on the following comma-separated list: +

+ +

Users to watch: + +

+ +

Users watching you:
+ [% IF watchers.size %] + [% FOREACH watcher = watchers %] + [% watcher FILTER html %]
+ [% END %] + [% ELSE %] + None + [% END %] +

+ +[% END %] + +
+
-- cgit v1.2.3-24-g4f1b