Commit 1e872832 authored by lpsolit%gmail.com's avatar lpsolit%gmail.com

Hum... 2nd attempt to fix bug 332149. I committed the wrong patch *and* I lost…

Hum... 2nd attempt to fix bug 332149. I committed the wrong patch *and* I lost connection in the middle of the commit. Bad!
parent 152f6136
......@@ -227,8 +227,7 @@ sub Send {
my $diffpart = {};
if ($who ne $lastwho) {
$lastwho = $who;
$fullwho = $whoname ? "$whoname <$who" . Bugzilla->params->{'emailsuffix'} . ">" :
"$who" . Bugzilla->params->{'emailsuffix'};
$fullwho = $whoname ? "$whoname <$who>" : $who;
$diffheader = "\n$fullwho changed:\n\n";
$diffheader .= FormatTriple("What ", "Removed", "Added");
$diffheader .= ('-' x 76) . "\n";
......@@ -703,14 +702,8 @@ sub prepare_comments {
my $result = "";
foreach my $comment (@$raw_comments) {
if ($count) {
my $author = $comment->{'author'};
$result .= "\n\n--- Comment #$count from ";
if ($author->name) {
$result .= $author->name . " <" . $author->email . ">";
} else {
$result .= $author->email;
}
$result .= " " . format_time($comment->{'time'}) . " ---\n";
$result .= "\n\n--- Comment #$count from " . $comment->{'author'}->identity .
" " . format_time($comment->{'time'}) . " ---\n";
}
# Format language specific comments. We don't update $comment->{'body'}
# directly, otherwise it would grow everytime you call format_comment()
......
......@@ -510,7 +510,7 @@ sub update_table_definitions {
# 2007-05-17 LpSolit@gmail.com - Bug 344965
_initialize_workflow($old_params);
# 2007-07-11 LpSolit@gmail.com - Bug 332149
# 2007-08-08 LpSolit@gmail.com - Bug 332149
$dbh->bz_add_column('groups', 'icon_url', {TYPE => 'TINYTEXT'});
################################################################
......
......@@ -42,6 +42,10 @@
<td><input size="40" name="desc"></td>
<td><input size="30" name="regexp"></td>
<td><input type="checkbox" name="isactive" value="1" checked></td>
</tr>
<tr>
<th>Icon URL:</th>
<td colspan="3"><input type="text" size="70" maxlength="255" id="icon_url" name="icon_url"></td>
</tr></table><hr>
<input type="checkbox" name="insertnew" value="1"
......@@ -75,6 +79,13 @@ case you should leave this checked.</b></p>
automatically grant membership to this group to anyone with an
email address that matches this regular expression.</p>
<p>
<b>Icon URL</b> is optional, and is the URL pointing to the icon
used to identify the group. It may be either a relative URL to the base URL
of this installation or an absolute URL. This icon will be displayed
in comments in [% terms.bugs %] besides the name of the author of comments.
</p>
<p>By default, the new group will be associated with existing
products. Unchecking the "Insert new group into all existing
products" option will prevent this and make the group become
......
......@@ -83,6 +83,19 @@
</td>
</tr>
<tr>
<th>
Icon URL:
[% IF group.icon_url %]
<img src="[% group.icon_url FILTER html %]" alt="[% group.name FILTER html %]">
[% END %]
</th>
<td>
<input type="text" name="icon_url" size="70" maxlength="255"
value="[% group.icon_url FILTER html %]">
</td>
</tr>
[% IF group.is_bug_group %]
<tr>
<th>Use For [% terms.Bugs %]:</th>
......
......@@ -172,10 +172,17 @@
<a name="c[% count %]" href="show_bug.cgi?id=[% bug.bug_id %]#c[% count %]">
#[% count %]</a> From
<span class="vcard">
<a class="fn email" href="mailto:[% comment.email FILTER html %]">
[% (comment.name || comment.email) FILTER html %]
<a class="fn email" href="mailto:[% comment.author.email FILTER html %]">
[% (comment.author.name || comment.author.login) FILTER html %]
</a>
</span>
[% FOREACH group = comment.author.direct_group_membership %]
[% NEXT UNLESS group.icon_url %]
<img src="[% group.icon_url FILTER html %]"
alt="[% group.name FILTER html %]"
title="[% group.name FILTER html %] - [% group.description FILTER html %]">
[% END %]
[%+ comment.time FILTER time %]
</i>
[% IF mode == "edit" %]
......
......@@ -69,7 +69,7 @@
[% FOREACH c = bug.longdescs %]
[% NEXT IF c.isprivate && !user.in_group(Param("insidergroup")) %]
<long_desc isprivate="[% c.isprivate FILTER xml %]">
<who name="[% c.name FILTER xml %]">[% c.email FILTER xml %]</who>
<who name="[% c.author.name FILTER xml %]">[% c.author.email FILTER xml %]</who>
<bug_when>[% c.time FILTER time FILTER xml %]</bug_when>
[% IF user.in_group(Param('timetrackinggroup')) && (c.work_time - 0 != 0) %]
<work_time>[% PROCESS formattimeunit time_unit = c.work_time FILTER xml %]</work_time>
......
......@@ -209,7 +209,7 @@
[% ELSIF message_tag == "group_updated" %]
[% IF changes.keys.size %]
The following changes have been made to the '[% group.name FILTER html %]
The following changes have been made to the '[% group.name FILTER html %]'
group:
<ul>
[% FOREACH field = changes.keys.sort %]
......@@ -226,6 +226,8 @@
[% ELSE %]
<li>The group will no longer be used for [% terms.bugs %].</li>
[% END %]
[% CASE 'icon_url' %]
<li>The group icon URL has been updated.</li>
[% CASE 'members_add' %]
<li>The following groups are now members of this group:
[%+ changes.members_add.join(', ') FILTER html %]</li>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment