summaryrefslogtreecommitdiffstats
path: root/extensions/RequestWhiner
diff options
context:
space:
mode:
Diffstat (limited to 'extensions/RequestWhiner')
-rw-r--r--extensions/RequestWhiner/bin/whineatrequests.pl13
-rw-r--r--extensions/RequestWhiner/template/en/default/requestwhiner/mail.html.tmpl26
-rw-r--r--extensions/RequestWhiner/template/en/default/requestwhiner/mail.txt.tmpl25
3 files changed, 39 insertions, 25 deletions
diff --git a/extensions/RequestWhiner/bin/whineatrequests.pl b/extensions/RequestWhiner/bin/whineatrequests.pl
index 622438b4f..b7ac8f029 100644
--- a/extensions/RequestWhiner/bin/whineatrequests.pl
+++ b/extensions/RequestWhiner/bin/whineatrequests.pl
@@ -40,7 +40,8 @@ my $dbh = Bugzilla->dbh;
my $sth_get_requests =
$dbh->prepare("SELECT profiles.login_name,
- flagtypes.name,
+ flagtypes.name,
+ flags.attach_id,
bugs.bug_id,
bugs.short_desc, " .
$dbh->sql_to_days('NOW()') .
@@ -68,6 +69,7 @@ my $requests = {};
while (my ($login_name,
$flag_name,
+ $attach_id,
$bug_id,
$short_desc,
$age_in_days) = $sth_get_requests->fetchrow_array())
@@ -81,9 +83,10 @@ while (my ($login_name,
}
push(@{ $requests->{$login_name}->{$flag_name} }, {
- id => $bug_id,
- summary => $short_desc,
- age => $age_in_days
+ bug_id => $bug_id,
+ attach_id => $attach_id,
+ summary => $short_desc,
+ age => $age_in_days
});
}
@@ -97,7 +100,7 @@ foreach my $recipient (keys %$requests) {
mail({
from => Bugzilla->params->{'mailfrom'},
recipient => $user,
- subject => "Outstanding Requests",
+ subject => "Your Outstanding Requests",
requests => $requests->{$recipient},
threshold => WHINE_AFTER_DAYS
});
diff --git a/extensions/RequestWhiner/template/en/default/requestwhiner/mail.html.tmpl b/extensions/RequestWhiner/template/en/default/requestwhiner/mail.html.tmpl
index de2c4dc6a..07b2b31ee 100644
--- a/extensions/RequestWhiner/template/en/default/requestwhiner/mail.html.tmpl
+++ b/extensions/RequestWhiner/template/en/default/requestwhiner/mail.html.tmpl
@@ -29,17 +29,27 @@
</head>
<body bgcolor="#FFFFFF">
-<p>Here are your outstanding requests older than [% threshold FILTER html%]
-days:</p>
+<p>The following is a list of requests people have made of you, which have been
+outstanding more than [% threshold FILTER html %] days. To avoid disappointing
+others, please deal with them as quickly as possible.
+(<a href="https://wiki.mozilla.org/BMO/Handling_Requests">Here is some
+guidance on handling requests</a>.)
+</p>
-[% FOREACH request = requests.keys %]
-<h3>[% request FILTER html %]</h3>
+[% FOREACH request_type = requests.keys %]
+<h3>[% request_type FILTER html %]</h3>
<ul>
- [% FOREACH bug = requests.$request %]
+ [% FOREACH request = requests.$request_type %]
<li>
- <a href="[% urlbase FILTER none %]show_bug.cgi?id=[% bug.id FILTER none %]">[% terms.Bug %]
- [%+ bug.id FILTER none %]: [% bug.summary FILTER html %]</a> ([% bug.age FILTER none %] days old)
+ <a href="[% urlbase FILTER none %]show_bug.cgi?id=[% request.bug_id FILTER none %]">[% terms.Bug %]
+ [%+ request.bug_id FILTER none %]: [% request.summary FILTER html %]</a> ([% request.age FILTER none %] days old)
+ [% IF request.attach_id %]
+ <br>
+ <small>(<a href="[% urlbase FILTER none %]attachment.cgi?id=[% request.attach_id FILTER none %]&action=edit">Details</a> |
+ <a href="[% urlbase FILTER none %]attachment.cgi?id=[% request.attach_id FILTER none %]&action=diff">Diff</a> |
+ <a href="[% urlbase FILTER none %]page.cgi?id=splinter.html&bug=[% request.bug_id FILTER none %]&attachment=[% request.attach_id FILTER none %]">Splinter Review</a>)</small>
+ [% END %]
</li>
[% END %]
</ul>
@@ -48,7 +58,5 @@ days:</p>
<p><a href="[% urlbase FILTER none %]request.cgi?action=queue&requestee=[% recipient.email FILTER uri %]&group=type">See all your outstanding requests</a>.</p>
-<p>A href="https://wiki.mozilla.org/BMO/Handling_Requests">Get guidance on handling requests</a>.</p>
-
</body>
</html>
diff --git a/extensions/RequestWhiner/template/en/default/requestwhiner/mail.txt.tmpl b/extensions/RequestWhiner/template/en/default/requestwhiner/mail.txt.tmpl
index a7cfd9668..c8091c057 100644
--- a/extensions/RequestWhiner/template/en/default/requestwhiner/mail.txt.tmpl
+++ b/extensions/RequestWhiner/template/en/default/requestwhiner/mail.txt.tmpl
@@ -20,19 +20,22 @@
[% PROCESS global/variables.none.tmpl %]
[% PROCESS 'global/field-descs.none.tmpl' %]
-Here are your outstanding requests older than [% threshold %] days:
+The following is a list of requests people have made of you, which have been
+outstanding more than [% threshold %] days. To avoid disappointing others, please deal with
+them as quickly as possible. Here is some guidance on handling requests:
+ https://wiki.mozilla.org/BMO/Handling_Requests
-[% FOREACH request = requests.keys %]
-[%+ request +%]
-[%+ "-" FILTER repeat(request.length) +%]
+[% FOREACH request_type = requests.keys %]
+[%+ request_type +%]
+[%+ "-" FILTER repeat(request_type.length) +%]
- [% FOREACH bug = requests.$request %]
- [%+ terms.Bug +%] [%+ bug.id %]: [% bug.summary +%] ([% bug.age %] days old)
- [%+ urlbase %]show_bug.cgi?id=[% bug.id +%]
+ [% FOREACH request = requests.$request_type %]
+ [%+ terms.Bug +%] [%+ request.bug_id %]: [% request.summary +%] ([% request.age %] days old)
+ [%+ urlbase %]show_bug.cgi?id=[% request.bug_id +%]
+ [% IF request.attach_id %]
+ [%+ urlbase %]attachment.cgi?id=[% request.attach_id %]&action=edit
+ [% END %]
[%+ END +%]
[% END %]
To see all your outstanding requests, visit:
-[%+ urlbase %]request.cgi?action=queue&requestee=[% recipient.email FILTER uri %]&group=type
-
-For guidance on handling requests, see:
-https://wiki.mozilla.org/BMO/Handling_Requests
+[%+ urlbase %]request.cgi?action=queue&requestee=[% recipient.email FILTER url_quote %]&group=type