summaryrefslogtreecommitdiff
path: root/rt/html/Ticket/Elements
diff options
context:
space:
mode:
authorivan <ivan>2004-12-03 20:40:48 +0000
committerivan <ivan>2004-12-03 20:40:48 +0000
commitd39d52aac8f38ea9115628039f0df5aa3ac826de (patch)
treec77529c4e4dbb9bf832fcef14538dc16b2f7a110 /rt/html/Ticket/Elements
parentc582e92888b4a5553e1b4e5214cf35217e4a0cf0 (diff)
import rt 3.2.2
Diffstat (limited to 'rt/html/Ticket/Elements')
-rw-r--r--rt/html/Ticket/Elements/AddWatchers38
-rw-r--r--rt/html/Ticket/Elements/BulkLinks38
-rw-r--r--rt/html/Ticket/Elements/EditBasics117
-rw-r--r--rt/html/Ticket/Elements/EditCustomField38
-rw-r--r--rt/html/Ticket/Elements/EditCustomFields38
-rw-r--r--rt/html/Ticket/Elements/EditDates38
-rw-r--r--rt/html/Ticket/Elements/EditPeople40
-rw-r--r--rt/html/Ticket/Elements/EditWatchers40
-rwxr-xr-xrt/html/Ticket/Elements/FindAttachments90
-rwxr-xr-xrt/html/Ticket/Elements/LoadTextAttachments45
-rwxr-xr-xrt/html/Ticket/Elements/PreviewScrips124
-rw-r--r--rt/html/Ticket/Elements/ShowAttachments42
-rw-r--r--rt/html/Ticket/Elements/ShowBasics59
-rw-r--r--rt/html/Ticket/Elements/ShowCustomFields38
-rw-r--r--rt/html/Ticket/Elements/ShowDates39
-rw-r--r--rt/html/Ticket/Elements/ShowDependencies38
-rw-r--r--rt/html/Ticket/Elements/ShowGroupMembers60
-rw-r--r--rt/html/Ticket/Elements/ShowHistory67
-rw-r--r--rt/html/Ticket/Elements/ShowMemberOf38
-rw-r--r--rt/html/Ticket/Elements/ShowMembers38
-rw-r--r--rt/html/Ticket/Elements/ShowMessageHeaders76
-rw-r--r--rt/html/Ticket/Elements/ShowMessageStanza38
-rw-r--r--rt/html/Ticket/Elements/ShowPeople45
-rw-r--r--rt/html/Ticket/Elements/ShowReferences38
-rw-r--r--rt/html/Ticket/Elements/ShowRequestor41
-rw-r--r--rt/html/Ticket/Elements/ShowSummary46
-rw-r--r--rt/html/Ticket/Elements/ShowTransaction241
-rw-r--r--rt/html/Ticket/Elements/ShowTransactionAttachments196
-rw-r--r--rt/html/Ticket/Elements/ShowUserEntry55
-rw-r--r--rt/html/Ticket/Elements/Tabs79
30 files changed, 1497 insertions, 423 deletions
diff --git a/rt/html/Ticket/Elements/AddWatchers b/rt/html/Ticket/Elements/AddWatchers
index 96dd38f08..f70e86a17 100644
--- a/rt/html/Ticket/Elements/AddWatchers
+++ b/rt/html/Ticket/Elements/AddWatchers
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<BR>
<%$msg%><br>
diff --git a/rt/html/Ticket/Elements/BulkLinks b/rt/html/Ticket/Elements/BulkLinks
index e6b9cd54f..c071bd1cc 100644
--- a/rt/html/Ticket/Elements/BulkLinks
+++ b/rt/html/Ticket/Elements/BulkLinks
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<TABLE>
<TR>
<TD class="label"><&|/l&>Merge into</&>:</TD>
diff --git a/rt/html/Ticket/Elements/EditBasics b/rt/html/Ticket/Elements/EditBasics
index 5d66b1fc1..7ad4a63b0 100644
--- a/rt/html/Ticket/Elements/EditBasics
+++ b/rt/html/Ticket/Elements/EditBasics
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,62 +20,71 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
-%# END LICENSE BLOCK
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
<TABLE>
- <TR><td>
- <table>
+ <TR>
<td class="label"><&|/l&>Subject</&>:</td>
- <td class="value">
- <input name=Subject value="<%$TicketObj->Subject|h%>" SIZE=50>
- </td>
- </table>
- </td></TR>
- <TR><td>
- <table>
- <TD>
- <& /Elements/ShadedBox,
- title => loc('Status'),
- content => $SelectStatus &>
- </TD>
- <TD>
- <& /Elements/ShadedBox,
- title => loc('Time Worked'),
- content => "<input name=TimeWorked value=\"".$TicketObj->TimeWorked."\" SIZE=5>" &>
- </TD>
- <TD>
- <& /Elements/ShadedBox,
- title => loc('Time Left'),
- content => "<input name=TimeLeft value=\"".$TicketObj->TimeLeft."\" SIZE=5>"
-&>
- </TD>
- <TD>
- <& /Elements/ShadedBox,
- title => loc('Priority'),
- content => "<input name=Priority value=\"".$TicketObj->Priority."\" SIZE=3>" &>
- </TD>
- <TD>
- <& /Elements/ShadedBox,
- title => loc('Final Priority'),
- content => "<input name=FinalPriority value=\"".$TicketObj->FinalPriority."\" SIZE=3>" &>
- </TD>
- <TD>
- <& /Elements/ShadedBox,
- title => loc('Queue'),
- content => "$SelectQueue" &>
- </TD>
- </table>
- </td></TR>
+ <td class="value"><input name=Subject value="<%$TicketObj->Subject|h%>" SIZE=50></td>
+ </TR>
+
+ <TR>
+ <td class="label"><&|/l&>Status</&>:</td>
+ <td class="value"><%$SelectStatus|n%></td>
+ </TR>
+ <TR>
+ <td class="label"><&|/l&>Queue</&>:</td>
+ <td class="value"><%$SelectQueue|n%></td>
+ </TR>
+ <TR>
+ <td class="label"><&|/l&>Time Estimated</&>:</td>
+ <td class="value"><input name=TimeEstimated value="<%$TicketObj->TimeEstimated|h%>" SIZE="5"></td>
+ </TR>
+ <TR>
+ <td class="label"><&|/l&>Time Worked</&>:</td>
+ <td class="value"><input name=TimeWorked value="<%$TicketObj->TimeWorked|h%>" SIZE="5"></td>
+ </TR>
+ <TR>
+ <td class="label"><&|/l&>Time Left</&>:</td>
+ <td class="value"><input name=TimeLeft value="<%$TicketObj->TimeLeft|h%>" SIZE="5"></td>
+ </TR>
+
+ <TR>
+ <td class="label"><&|/l&>Priority</&>:</td>
+ <td class="value"><input name=Priority value="<%$TicketObj->Priority|h%>" SIZE="5"></td>
+ </TR>
+
+ <TR>
+ <td class="label"><&|/l&>Final Priority</&>:</td>
+ <td class="value"><input name=FinalPriority value="<%$TicketObj->FinalPriority|h%>" SIZE="5"></td>
+ </TR>
+<& /Elements/Callback, _CallbackName => 'EndOfList', TicketObj => $TicketObj, %ARGS &>
</TABLE>
<%INIT>
#It's hard to do this inline, so we'll preload the html of the selectstatus in here.
-my $SelectStatus = $m->scomp("/Elements/SelectStatus", Name => 'Status', Default=> $TicketObj->Status);
+my $SelectStatus = $m->scomp("/Elements/SelectStatus", Name => 'Status', DefaultLabel => loc("[_1] (Unchanged)",$TicketObj->Status));
my $SelectQueue = $m->scomp("/Elements/SelectQueue", Name => 'Queue', Default =>$TicketObj->QueueObj->Id);
</%INIT>
diff --git a/rt/html/Ticket/Elements/EditCustomField b/rt/html/Ticket/Elements/EditCustomField
index 16348061e..74e57ddf3 100644
--- a/rt/html/Ticket/Elements/EditCustomField
+++ b/rt/html/Ticket/Elements/EditCustomField
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
% my $Values;
% if ($TicketObj) {
% $Values = $TicketObj->CustomFieldValues($CustomField->id);
diff --git a/rt/html/Ticket/Elements/EditCustomFields b/rt/html/Ticket/Elements/EditCustomFields
index 6b2738965..b049751ff 100644
--- a/rt/html/Ticket/Elements/EditCustomFields
+++ b/rt/html/Ticket/Elements/EditCustomFields
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<table>
<tr>
<td valign="top" width="50%">
diff --git a/rt/html/Ticket/Elements/EditDates b/rt/html/Ticket/Elements/EditDates
index 1f3bf1b49..8e12f2534 100644
--- a/rt/html/Ticket/Elements/EditDates
+++ b/rt/html/Ticket/Elements/EditDates
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<TABLE>
<TR>
<TD class="label"><&|/l&>Starts</&>:</TD>
diff --git a/rt/html/Ticket/Elements/EditPeople b/rt/html/Ticket/Elements/EditPeople
index a1fc0111a..4b2a1ac81 100644
--- a/rt/html/Ticket/Elements/EditPeople
+++ b/rt/html/Ticket/Elements/EditPeople
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<TABLE>
<TR>
<TD VALIGN=TOP>
@@ -40,7 +62,7 @@
GroupField => $GroupField, PrivilegedOnly => $PrivilegedOnly &>
</TD><TD VALIGN=TOP>
<h3><&|/l&>Owner</&></h3>
-<&|/l&>Owner</&>: <& /Elements/SelectOwner, Name => 'Owner', QueueObj => $Ticket->QueueObj, TicketObj => $Ticket, Default => $Ticket->OwnerObj->Id &>
+<&|/l&>Owner</&>: <& /Elements/SelectOwner, Name => 'Owner', QueueObj => $Ticket->QueueObj, TicketObj => $Ticket, Default => $Ticket->OwnerObj->Id, DefaultValue => 0&>
<h3><&|/l&>Current watchers</&></h3>
<&|/l&>(Check box to delete)</&><br>
diff --git a/rt/html/Ticket/Elements/EditWatchers b/rt/html/Ticket/Elements/EditWatchers
index 145071cec..19c884bd8 100644
--- a/rt/html/Ticket/Elements/EditWatchers
+++ b/rt/html/Ticket/Elements/EditWatchers
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<ul>
%# Print out a placeholder if there are none.
%if ($Members->Count == 0 ) {
@@ -30,7 +52,7 @@
%while (my $watcher=$Members->Next) {
<li>
-<INPUT TYPE=CHECKBOX NAME="Ticket-DelWatcher-Type-<%$Watchers->Type%>-Principal-<%$watcher->MemberId%>" UNCHECKED>
+<INPUT TYPE=CHECKBOX NAME="Ticket-DeleteWatcher-Type-<%$Watchers->Type%>-Principal-<%$watcher->MemberId%>" UNCHECKED>
%if ($watcher->MemberObj->IsUser) {
<a href="<%$RT::WebPath%>/Admin/Users/Modify.html?id=<%$watcher->MemberObj->Object->id%>">
<%$watcher->MemberObj->Object->Name%></a>
diff --git a/rt/html/Ticket/Elements/FindAttachments b/rt/html/Ticket/Elements/FindAttachments
index b8a0dd8b6..a1e973f0e 100755
--- a/rt/html/Ticket/Elements/FindAttachments
+++ b/rt/html/Ticket/Elements/FindAttachments
@@ -1,3 +1,48 @@
+%# {{{ BEGIN BPS TAGGED BLOCK
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
<%INIT>
my %documents;
@@ -6,41 +51,40 @@ my %documents;
# We force the cache of ticket transactions to get populated up front. otherwise, the
# code that looks at attachments will look at each one in turn.
-my $transactions = $Ticket->Transactions->First;
-
-
my $attachments = RT::Attachments->new( $session{'CurrentUser'} );
$attachments->Columns( qw( Id Filename ContentType Headers Subject Parent ContentEncoding ContentType TransactionId Created));
-if ( $Ticket->CurrentUserHasRight('ShowTicket') ) {
- my $transactions = $attachments->NewAlias('Transactions');
- $attachments->Join( ALIAS1 => 'main',
- FIELD1 => 'TransactionId',
- ALIAS2 => $transactions,
- FIELD2 => 'id' );
+my $transactions = $attachments->NewAlias('Transactions');
+$attachments->Join( ALIAS1 => 'main',
+ FIELD1 => 'TransactionId',
+ ALIAS2 => $transactions,
+ FIELD2 => 'id' );
- my $tickets = $attachments->NewAlias('Tickets');
+my $tickets = $attachments->NewAlias('Tickets');
- $attachments->Join( ALIAS1 => $transactions,
- FIELD1 => 'Ticket',
- ALIAS2 => $tickets,
- FIELD2 => 'id' );
+$attachments->Join( ALIAS1 => $transactions,
+ FIELD1 => 'Ticket',
+ ALIAS2 => $tickets,
+ FIELD2 => 'id' );
- $attachments->Limit( ALIAS => $tickets,
- FIELD => 'EffectiveId',
- VALUE => $Ticket->id() );
- # if the user may not see comments do not return them
- unless ( $Ticket->CurrentUserHasRight('ShowTicketComments') ) {
- $attachments->Limit( ALIAS => $transactions,
- FIELD => 'Type',
- OPERATOR => '!=',
- VALUE => "Comment" );
+if ($Tickets) {
+ while ($Ticket = $Tickets->Next) {
+ $attachments->Limit( ALIAS => $tickets,
+ FIELD => 'EffectiveId',
+ VALUE => $Ticket->id() );
}
+} else {
+ $attachments->Limit( ALIAS => $tickets,
+ FIELD => 'EffectiveId',
+ VALUE => $Ticket->id() );
}
+
+
return ($attachments);
</%INIT>
<%ARGS>
$Ticket => undef
+$Tickets => undef
</%ARGS>
diff --git a/rt/html/Ticket/Elements/LoadTextAttachments b/rt/html/Ticket/Elements/LoadTextAttachments
index 084502e4c..370371b5a 100755
--- a/rt/html/Ticket/Elements/LoadTextAttachments
+++ b/rt/html/Ticket/Elements/LoadTextAttachments
@@ -1,3 +1,48 @@
+%# {{{ BEGIN BPS TAGGED BLOCK
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
<%INIT>
my $attachments = RT::Attachments->new( $session{'CurrentUser'} );
diff --git a/rt/html/Ticket/Elements/PreviewScrips b/rt/html/Ticket/Elements/PreviewScrips
new file mode 100755
index 000000000..846c62c24
--- /dev/null
+++ b/rt/html/Ticket/Elements/PreviewScrips
@@ -0,0 +1,124 @@
+%# {{{ BEGIN BPS TAGGED BLOCK
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
+<%args>
+$TicketObj => undef
+
+</%args>
+<%init>
+
+my $arg = 'Ticket-'.$TicketObj->Id.'-SquelchMailTo';
+my @squelchto = ref($ARGS{$arg}) eq 'ARRAY' ? @{$ARGS{$arg}} : ($ARGS{$arg});
+
+foreach my $address (@squelchto) {
+ $TicketObj->SquelchMailTo($address) if ($address);
+}
+
+
+$arg = 'Ticket-'.$TicketObj->Id.'-UnsquelchMailTo';
+my @unsquelchto = ref($ARGS{$arg}) eq 'ARRAY' ? @{$ARGS{$arg}} : ($ARGS{$arg});
+
+foreach my $address (@unsquelchto) {
+ $TicketObj->UnsquelchMailTo($address) if ($address);
+}
+
+
+my $action;
+
+if (( $ARGS{'UpdateType'} eq 'response' ) || ($ARGS{'Action'} eq 'Respond' )) {
+ $action = 'Correspond';
+}
+else {
+ $action = 'Comment';
+}
+
+my $Message = MakeMIMEEntity(
+ Subject => $ARGS{'UpdateSubject'},
+ Body => $ARGS{'UpdateContent'},
+);
+
+my ( $Transaction, $Description, $Object ) = $TicketObj->$action(
+ CcMessageTo => $ARGS{'UpdateCc'},
+ BccMessageTo => $ARGS{'UpdateBcc'},
+ MIMEObj => $Message,
+ TimeTaken => $ARGS{'UpdateTimeWorked'},
+ DryRun => 1
+);
+
+
+my @non_recipients = $TicketObj->SquelchMailTo;
+</%init>
+<h2><&|/l&>This message will be sent to...</&></h2>
+<i><&|/l&>(Check boxes to disable notifications to the listed recipients)</&></i><br>
+% foreach my $scrip (@{$Object->Scrips->Prepared}) {
+% next unless $scrip->ActionObj->Action->isa('RT::Action::SendEmail');
+<b><%$scrip->Description%></b><br>
+<&|/l, $scrip->ConditionObj->Name, $scrip->ActionObj->Name, $scrip->TemplateObj->Name&>[_1] [_2] with template [_3]</&>
+<br>
+%foreach my $type qw(To Cc Bcc) {
+%my @addresses = $scrip->ActionObj->Action->$type();
+<ul>
+%foreach my $addr (@addresses) {
+<li> <b><%loc($type)%></b>: <input type="checkbox" name="Ticket-<%$TicketObj->id%>-SquelchMailTo" value="<%$addr->address%>"> <%$addr->address%>
+% }
+</ul>
+% }
+% if ($RT::PreviewScripMessages) {
+<textarea cols=80 rows="5">
+<%$scrip->ActionObj->TemplateObj->MIMEObj->as_string%>
+</textarea>
+% }
+%}
+<br>
+<h2><&|/l&>Messages about this ticket will not be sent to...</&></h2>
+<i><&|/l&>(Check boxes to enable notifications to the listed recipients)</&></i>
+<br>
+<ul>
+% foreach my $recipient (@non_recipients) {
+<li><input type="checkbox" name="Ticket-<%$TicketObj->id%>-UnsquelchMailTo" value="<%$recipient->Content%>">
+<% $recipient->Content %>
+% }
+</ul>
+<& /Elements/Submit, Value => 'UpdatePreview', Label => loc('Save changes')&>
diff --git a/rt/html/Ticket/Elements/ShowAttachments b/rt/html/Ticket/Elements/ShowAttachments
index bdda1692c..8a2a5cb3f 100644
--- a/rt/html/Ticket/Elements/ShowAttachments
+++ b/rt/html/Ticket/Elements/ShowAttachments
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,20 +20,35 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
% if (keys %documents) {
<& /Elements/TitleBoxStart, title => loc('Attachments'),
title_class=> 'inverse',
color => "#336699" &>
% foreach my $key (keys %documents) {
-% my $fontsize='size="-1"';
<%$key%><br>
<ul>
@@ -46,13 +67,12 @@ if ($size) {
</%PERL>
-<li><font <%$fontsize%>>
+<li><font size="-2">
<A HREF="<%$RT::WebPath%>/Ticket/Attachment/<%$rev->TransactionId%>/<%$rev->Id%>/<%$rev->Filename | u%>">
<&|/l, $rev->CreatedAsString, $size, $rev->CreatorObj->Name &>[_1] ([_2]) by [_3]</&>
</a>
</font></li>
% }
-% $fontsize='size="-2"';
% }
</ul>
diff --git a/rt/html/Ticket/Elements/ShowBasics b/rt/html/Ticket/Elements/ShowBasics
index ad23e8c8c..55e923fa2 100644
--- a/rt/html/Ticket/Elements/ShowBasics
+++ b/rt/html/Ticket/Elements/ShowBasics
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<table>
<tr>
<td class="label"><&|/l&>Id</&>:</td>
@@ -30,9 +52,21 @@
<td class="label"><&|/l&>Status</&>:</td>
<td class="value"><&|/l&><% $Ticket->Status%></&></td>
</tr>
+% if ($Ticket->TimeEstimated) {
+ <tr>
+ <td class="label"><&|/l&>Estimated</&>:</td>
+ <td class="value"><&|/l, $Ticket->TimeEstimated &>[_1] min</&></td>
+ </tr>
+% }
+% if ($Ticket->TimeWorked) {
<tr>
<td class="label"><&|/l&>Worked</&>:</td>
- <td class="value"><&|/l, $TimeWorked &>[_1] min</&></td>
+ <td class="value"><&|/l, $Ticket->TimeWorked &>[_1] min</&></td>
+ </tr>
+% }
+ <tr>
+ <td class="label"><&|/l&>Left</&>:</td>
+ <td class="value"><&|/l, $Ticket->TimeLeft &>[_1] min</&></td>
</tr>
<tr>
<td class="label"><&|/l&>Priority</&>:</td>
@@ -42,13 +76,8 @@
<td class="label"><&|/l&>Queue</&>:</td>
<td class="value"><%$Ticket->QueueObj->Name%></td>
</tr>
+<& /Elements/Callback, _CallbackName => 'EndOfList', TicketObj => $Ticket, %ARGS &>
</table>
-<%INIT>
-my $TimeWorked = $Ticket->TimeWorked;
-if ($Ticket->TimeLeft > 0 ) {
- $TimeWorked = $Ticket->TimeWorked."/".$Ticket->TimeLeft;
-}
-</%INIT>
<%ARGS>
$Ticket => undef
</%ARGS>
diff --git a/rt/html/Ticket/Elements/ShowCustomFields b/rt/html/Ticket/Elements/ShowCustomFields
index 50d28f0d1..895439e1b 100644
--- a/rt/html/Ticket/Elements/ShowCustomFields
+++ b/rt/html/Ticket/Elements/ShowCustomFields
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<table>
% my @entry_fields;
% while (my $CustomField = $CustomFields->Next()) {
diff --git a/rt/html/Ticket/Elements/ShowDates b/rt/html/Ticket/Elements/ShowDates
index 70c95efc0..a22a02d5c 100644
--- a/rt/html/Ticket/Elements/ShowDates
+++ b/rt/html/Ticket/Elements/ShowDates
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,14 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
-
+%# }}} END BPS TAGGED BLOCK
<TABLE>
<TR>
<TD class="label"><&|/l&>Created</&>:</TD>
diff --git a/rt/html/Ticket/Elements/ShowDependencies b/rt/html/Ticket/Elements/ShowDependencies
index b7f396871..d3bdd59bc 100644
--- a/rt/html/Ticket/Elements/ShowDependencies
+++ b/rt/html/Ticket/Elements/ShowDependencies
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<&|/l&>Depends on</&>:<BR>
% while (my $Link = $Ticket->DependsOn->Next) {
% my $member = $Link->TargetObj;
diff --git a/rt/html/Ticket/Elements/ShowGroupMembers b/rt/html/Ticket/Elements/ShowGroupMembers
new file mode 100644
index 000000000..1d6e71182
--- /dev/null
+++ b/rt/html/Ticket/Elements/ShowGroupMembers
@@ -0,0 +1,60 @@
+%# {{{ BEGIN BPS TAGGED BLOCK
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
+%# Released under the terms of version 2 of the GNU Public License
+
+% my $UserMembers = $Group->UserMembersObj;
+% while (my $member = $UserMembers->Next()) {
+<& ShowUserEntry, User => $member &><br>
+% }
+% my $GroupMembers = $Group->MembersObj;
+% $GroupMembers->LimitToGroups();
+% while (my $member = $GroupMembers->Next()) {
+<&|/l&>Group</&>: <%$member->MemberObj->Object->Name%><br>
+% }
+
+<%ARGS>
+$Group => undef
+</%ARGS> \ No newline at end of file
diff --git a/rt/html/Ticket/Elements/ShowHistory b/rt/html/Ticket/Elements/ShowHistory
index c4fe41747..37b670d82 100644
--- a/rt/html/Ticket/Elements/ShowHistory
+++ b/rt/html/Ticket/Elements/ShowHistory
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
%#
+%# CONTRIBUTION SUBMISSION POLICY:
%#
-%# END LICENSE BLOCK
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
<%perl>
if ($ShowDisplayModes or $ShowTitle) {
my $title;
@@ -32,7 +54,7 @@ else {
$title = '&nbsp;';
}
$titleright = loc('Display mode') . ":";
-if ($ShowHeaders && $ShowHeaders == $Ticket->Id ) {
+if ($ShowHeaders) {
$titleright .= "[<A HREF=\"" . $URIFile . "?id="
. $Ticket->id . "\">"
. loc("Brief headers")
@@ -44,8 +66,8 @@ else {
. loc("Brief headers")
. "]</b> [<A HREF=\""
. $URIFile
- . "?ShowHeaders="
- . $Ticket->Id . "&id="
+ . "?ShowHeaders=1"
+ . "&id="
. $Ticket->id . "\">"
. loc("Full headers") . "</a>]";
}
@@ -72,8 +94,6 @@ while ( my $Transaction = $Transactions->Next ) {
next if $skip;
$i++;
- $m->out('<a name="lasttrans"></a>') if ( $Transactions->IsLast );
-
my @trans_attachments = grep { $_->TransactionId == $Transaction->Id } @attachments;
my $trans_content = {};
@@ -93,7 +113,8 @@ while ( my $Transaction = $Transactions->Next ) {
RowNum => $i,
ShowTitleBarCommands => $ShowTitleBarCommands,
Attachments => \@trans_attachments,
- AttachmentContent => $trans_content
+ AttachmentContent => $trans_content,
+ LastTransaction => $Transactions->IsLast
);
}
@@ -103,20 +124,26 @@ while ( my $Transaction = $Transactions->Next ) {
<& /Elements/TitleBoxEnd &>
% }
<%INIT>
-
-my $Transactions = $Ticket->Transactions;
+my $Transactions = new RT::Transactions($session{'CurrentUser'});
+if ($Tickets) {
+ while (my $t = $Tickets->Next) {
+ $Transactions->Limit(FIELD => 'Ticket',
+ OPERATOR => '=',
+ VALUE => $t->Id);
+ }
+} else {
+ $Transactions = $Ticket->Transactions;
+}
my $i;
-
-$Attachments ||= $m->comp('/Ticket/Elements/FindAttachments', Ticket => $Ticket);
+$Attachments ||= $m->comp('/Ticket/Elements/FindAttachments', Ticket => $Ticket, Tickets => $Tickets || undef);
$AttachmentContent ||= $m->comp('/Ticket/Elements/LoadTextAttachments', Ticket => $Ticket);
-
-
</%INIT>
<%ARGS>
$URIFile => $RT::WebPath."/Ticket/Display.html"
$Ticket => undef
+$Tickets => undef
$Attachments => undef
$AttachmentContent => undef
$ShowHeaders => undef
diff --git a/rt/html/Ticket/Elements/ShowMemberOf b/rt/html/Ticket/Elements/ShowMemberOf
index 79e0a3ba2..eb285d34b 100644
--- a/rt/html/Ticket/Elements/ShowMemberOf
+++ b/rt/html/Ticket/Elements/ShowMemberOf
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<UL>
% my $memberof = $Ticket->MemberOf;
% while (my $member_of = $memberof->Next) {
diff --git a/rt/html/Ticket/Elements/ShowMembers b/rt/html/Ticket/Elements/ShowMembers
index e1016626a..9802e8982 100644
--- a/rt/html/Ticket/Elements/ShowMembers
+++ b/rt/html/Ticket/Elements/ShowMembers
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
% if ($members->Count) {
<UL>
% while (my $link = $members->Next) {
diff --git a/rt/html/Ticket/Elements/ShowMessageHeaders b/rt/html/Ticket/Elements/ShowMessageHeaders
index 11d873c3e..408b2c898 100644
--- a/rt/html/Ticket/Elements/ShowMessageHeaders
+++ b/rt/html/Ticket/Elements/ShowMessageHeaders
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,19 +20,69 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
-<%$content |n%>
+%# }}} END BPS TAGGED BLOCK
+% use Data::Dumper;
+<table>
+% foreach my $header (@headers) {
+% next unless ($display_headers{'_all'} || $display_headers{lc($header->{'Tag'})});
+<tr>
+<td align="right" class="message-header-key"><%$header->{'Tag'}%>:</td>
+<td class="message-header-value"><%$header->{'Value'} | n%></td>
+</tr>
+% }
+</table>
<%INIT>
my $content = $Headers;
-RT::Interface::Web::EscapeUTF8(\$content);
$m->comp('/Elements/Callback', content => \$content, %ARGS);
+
+# apply html escaping on the original content
+# we'll display the value without escaping later (for MakeClicky et al.)
+$content = $m->interp->apply_escapes($content, 'h');
+
+my @lines = split (/\n/,$content);
+my $in_header = 0;
+my @headers =();
+foreach (@lines) {
+ if (/^(\S+):\s+(.*)$/) {
+ push (@headers, { Tag => $1, Value => $2} );
+ } elsif ($headers[-1]) {
+ $headers[-1]->{'Value'} .= $_;
+ } else {
+
+ push (@headers, { Tag => $_, Value => ''} );
+ }
+}
+
+my %display_headers;
+
+map { $display_headers{lc($_)} = 1 } @$DisplayHeaders;
+
+$m->comp('/Elements/Callback', _CallbackName => 'Headers', content => \$content, headers => \@headers, display_headers => \%display_headers, %ARGS);
+
</%INIT>
<%ARGS>
$Headers => undef
+$DisplayHeaders => undef
</%ARGS>
diff --git a/rt/html/Ticket/Elements/ShowMessageStanza b/rt/html/Ticket/Elements/ShowMessageStanza
index 8e3045a36..8b912612b 100644
--- a/rt/html/Ticket/Elements/ShowMessageStanza
+++ b/rt/html/Ticket/Elements/ShowMessageStanza
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
% if (ref($Message)) {
<font color="<%$colors[$Depth]%>">
<%perl>
diff --git a/rt/html/Ticket/Elements/ShowPeople b/rt/html/Ticket/Elements/ShowPeople
index 160da70d9..597a991d5 100644
--- a/rt/html/Ticket/Elements/ShowPeople
+++ b/rt/html/Ticket/Elements/ShowPeople
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<table>
<tr>
<td class="label"><&|/l&>Owner</&>:</td>
@@ -28,18 +50,17 @@
</tr>
<tr>
<td class="labeltop"><&|/l&>Requestors</&>:</td>
- <td class="value"><%$Ticket->RequestorAddresses%></td>
+ <td class="value"><& ShowGroupMembers, Group => $Ticket->Requestors &></td>
</tr>
<tr>
<td class="labeltop"><&|/l&>Cc</&>:</td>
- <td class="value"><%$Ticket->CcAddresses%></td>
+ <td class="value"><& ShowGroupMembers, Group => $Ticket->Cc &></td>
</tr>
<tr>
<td class="labeltop"><&|/l&>AdminCc</&>:</td>
- <td class="value"><%$Ticket->AdminCcAddresses%></td>
+ <td class="value"><& ShowGroupMembers, Group => $Ticket->AdminCc &></td>
</tr>
</table>
<%ARGS>
$Ticket => undef
</%ARGS>
-
diff --git a/rt/html/Ticket/Elements/ShowReferences b/rt/html/Ticket/Elements/ShowReferences
index 831923b2b..e3639d01d 100644
--- a/rt/html/Ticket/Elements/ShowReferences
+++ b/rt/html/Ticket/Elements/ShowReferences
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<UL>
% while (my $Link = $Ticket->RefersTo->Next) {
<LI>
diff --git a/rt/html/Ticket/Elements/ShowRequestor b/rt/html/Ticket/Elements/ShowRequestor
index a6398efc7..cb9d7a6cc 100644
--- a/rt/html/Ticket/Elements/ShowRequestor
+++ b/rt/html/Ticket/Elements/ShowRequestor
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
%#
+%# CONTRIBUTION SUBMISSION POLICY:
%#
-%# END LICENSE BLOCK
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
<%PERL>
my $rows = 10;
my $people = $Ticket->Requestors->UserMembersObj;
@@ -39,6 +61,9 @@ $tickets->OrderBy(FIELD => 'Priority',
<& /Elements/TitleBoxStart,
title => "<a class='inverse' href=\"$RT::WebPath/Admin/Users/Modify.html?id=".$requestor->id."\">".loc("More about [_1]", $name)."</a>" &>
+%# Additional information about this user. Empty by default.
+<& /Elements/Callback, _CallbackName => 'AboutThisUser', requestor => $requestor, %ARGS &>
+
<&|/l&>Comments about this user</&>:<BR>
<B><% ($requestor->Comments || loc("No comment entered about this user")) %></B><BR>
diff --git a/rt/html/Ticket/Elements/ShowSummary b/rt/html/Ticket/Elements/ShowSummary
index 5bcc94b41..5540417c7 100644
--- a/rt/html/Ticket/Elements/ShowSummary
+++ b/rt/html/Ticket/Elements/ShowSummary
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,16 +20,32 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<TABLE WIDTH="100%" class="ticketsummary" >
<TR>
- <TD VALIGN=TOP WIDTH="50%">
+ <TD VALIGN=TOP WIDTH="50%" class="boxcontainer">
<& /Elements/TitleBoxStart, title => loc('The Basics'),
title_href =>"$RT::WebPath/Ticket/Modify.html?id=".$Ticket->Id,
title_class=> 'inverse',
@@ -49,7 +71,7 @@
<& /Elements/TitleBoxEnd &>
<BR>
</TD>
- <TD VALIGN=TOP WIDTH="50%">
+ <TD VALIGN=TOP WIDTH="50%" class="boxcontainer">
<& /Elements/TitleBoxStart, title => loc("Dates"),
title_href =>"$RT::WebPath/Ticket/ModifyDates.html?id=".$Ticket->Id,
@@ -58,11 +80,11 @@
<& /Ticket/Elements/ShowDates, Ticket => $Ticket &>
<& /Elements/TitleBoxEnd &>
<BR>
- <& /Elements/TitleBoxStart, title => loc('Relationships'),
+ <& /Elements/TitleBoxStart, title => loc('Links'),
title_href => "$RT::WebPath/Ticket/ModifyLinks.html?id=".$Ticket->Id,
title_class=> 'inverse',
titleright => '', color=> "#336633" &>
- <& /Ticket/Elements/ShowLinks, Ticket => $Ticket &>
+ <& /Elements/ShowLinks, Ticket => $Ticket &>
<& /Elements/TitleBoxEnd &>
<BR>
<& /Ticket/Elements/ShowAttachments, Ticket => $Ticket, Attachments => $Attachments &>
diff --git a/rt/html/Ticket/Elements/ShowTransaction b/rt/html/Ticket/Elements/ShowTransaction
index 8cde03870..f0b8326cf 100644
--- a/rt/html/Ticket/Elements/ShowTransaction
+++ b/rt/html/Ticket/Elements/ShowTransaction
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,15 +20,31 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<TR class="<% $RowNum%2 ? 'oddline' : 'evenline'%>" >
-<TD bgcolor="<%$bgcolor%>"><A NAME="txn-<%$Transaction->Id%>" href="#txn-<%$Transaction->Id%>">#</A>&nbsp;</TD>
+<TD rowspan="2" valign="top" bgcolor="<%$bgcolor%>"><A NAME="txn-<%$Transaction->Id%>" href="#txn-<%$Transaction->Id%>">#</A><% $LastTransaction ? '<a name="lasttrans">&nbsp;</a>' : '&nbsp;' |n %></TD>
<TD>&nbsp&nbsp;</TD>
<TD><font size=-2><% $transdate|n %></font>&nbsp;</TD>
% my $desc = $Transaction->BriefDescription;
@@ -33,89 +55,10 @@
<TD><%$TimeTaken%>&nbsp;</TD>
<TD ALIGN="RIGHT"><font size=-1><%$titlebar_commands|n%></font></TD>
</TR>
-<%PERL>
-
-unless ($Collapsed) {
- foreach my $message (@$Attachments) {
-
- my ($headers, $quoted);
- if ($ShowHeaders && ($ShowHeaders == $Ticket->Id)) {
- $headers = $message->Headers;
- } else {
- $headers = $message->NiceHeaders;
- }
- chomp $headers;
- if ($headers) {
- # localize the common headers (like 'Subject:'), too.
- eval {$headers =~ s/^([^:]+)(?=:)/loc($1)/em; } # we eval here to catch errors when 5.6 panics
- }
-
-
- my $MAX_INLINE_BODY = $RT::MaxInlineBody || 13456;
- if ( $message->ContentType =~ m{^(text/plain|message|text$)}i
- && $message->ContentLength < $MAX_INLINE_BODY ) {
-
- my $content;
- # If we've preloaded all the content, let's pull from there
- # if we haven't, load it now
- if ($AttachmentContent->{$message->id}) {
- $content = $AttachmentContent->{$message->id}->Content;
- } else {
- $content = $message->Content;
- }
-
-
-
- eval {
- require Text::Quoted;
- $quoted = Text::Quoted::extract( $content );
- };
- if ($@) {
- $quoted = $content;
- }
- }
-
-</%PERL>
-<TR class="<% $RowNum%2 ? 'oddline' : 'evenline'%>" >
- <TD BGCOLOR="<%$bgcolor%>">&nbsp;&nbsp;</TD>
- <TD>&nbsp;&nbsp;</TD>
- <TD COLSPAN=3 VALIGN=TOP>
-<span class="message">
- <PRE>
-<& ShowMessageHeaders, Headers => $headers, Transaction => $Transaction &>
-</PRE>
-% if ($message->ContentLength && !length($quoted) && $message->ContentType =~ m#^text/#) {
-<blockquote><i><&|/l&>Message body not shown because it is too large or is not plain text.</&><br>
-<&|/l&>You can access it with the Download button on the right.</&></i></blockquote>
-% } else {
-<& ShowMessageStanza, Depth => 0, Message => $quoted, Transaction => $Transaction &>
-% }
-</span>
- </TD>
- <TD VALIGN=TOP ALIGN=RIGHT>
-
-% if ($message->Parent == 0 ) {
-<BR>
-% }
-<%PERL>
-my $size = $message->ContentLength or next;
-
-if ($size) {
- if ($size > 1024) {
- $size = loc("[_1]k", int($size/102.4)/10);
- }
- else {
- $size = loc("[_1]b", $size);
- }
-</%PERL>
-<font size=-1><A HREF="<%$AttachPath%>/<%$Transaction->Id%>/<%$message->Id%>/<%$message->Filename | u%>"><&|/l&>Download</&> <% $message->Filename|| loc('(untitled)') %></a> <% $size %></font>
-% }
+<TR class="<% $RowNum%2 ? 'oddline' : 'evenline'%>"><TD colspan=5>
+% $m->comp('ShowTransactionAttachments', %ARGS, Parent => 0) unless ($Collapsed ||!$ShowBody);
</TD>
</TR>
-% }
-% }
-
-
<%ARGS>
$Ticket => undef
@@ -126,44 +69,56 @@ $ShowTitleBarCommands => 1
$RowNum => 1
$AttachPath => $RT::WebPath."/Ticket/Attachment"
$UpdatePath => $RT::WebPath."/Ticket/Update.html"
+$EmailRecordPath => $RT::WebPath."/Ticket/ShowEmailRecord.html"
$Attachments => undef
$AttachmentContent => undef
+$ShowBody => 1
+$LastTransaction => 0
</%ARGS>
<%INIT>
-
-my ($TimeTaken, $TicketString, $bgcolor);
+my ( $TimeTaken, $TicketString, $bgcolor );
my $transdate = $Transaction->CreatedAsString();
$transdate =~ s/\s/&nbsp;/g;
-if ($Transaction->Type =~ /^(Create|Correspond|Comment$)/) {
- $bgcolor="#336699";
-} elsif (($Transaction->Field =~ /^Owner$/) or
- ($Transaction->Type =~ /^(AddWatcher|DelWatcher)$/)) {
- $bgcolor="#333399";
-
-} elsif ($Transaction->Type =~ /^(AddLink|DeleteLink)$/) {
- $bgcolor="#336633";
-} elsif ($Transaction->Type =~ /^(Status|Set|Told)$/) {
- if ($Transaction->Field =~ /^(Told|Starts|Started|Due)$/) {
- $bgcolor="#663366";
- }
- else {
- $bgcolor="#993333";
- }
+if ( $Transaction->Type =~ /^(Create|Correspond|Comment$)/ ) {
+ if ( $Transaction->IsInbound ) {
+ $bgcolor = "#336699";
+ }
+ else {
+ $bgcolor = "#339999";
+ }
+}
+elsif ( ( $Transaction->Field =~ /^Owner$/ )
+ or ( $Transaction->Type =~ /^(AddWatcher|DelWatcher)$/ ) ) {
+ $bgcolor = "#333399";
+
+}
+elsif ( $Transaction->Type =~ /^(AddLink|DeleteLink)$/ ) {
+ $bgcolor = "#336633";
+}
+elsif ( $Transaction->Type =~ /^(Status|Set|Told)$/ ) {
+ if ( $Transaction->Field =~ /^(Told|Starts|Started|Due)$/ ) {
+ $bgcolor = "#663366";
+ }
+ else {
+ $bgcolor = "#993333";
+ }
}
else {
- $bgcolor="#cccccc";
+ $bgcolor = "#cccccc";
}
-if ($Ticket->Id != $Transaction->Ticket) {
- $TicketString = "Ticket ".$Transaction->Ticket .": ";
+if ( $Ticket->Id != $Transaction->Ticket ) {
+ $TicketString = "Ticket " . $Transaction->Ticket . ": ";
}
-if ($Transaction->TimeTaken != 0) {
- $TimeTaken = $Transaction->TimeTaken." min"
+if ( $Transaction->TimeTaken != 0 ) {
+ $TimeTaken = $Transaction->TimeTaken . " min";
+} else {
+ $TimeTaken = '';
}
unless ($Attachments) {
@@ -171,24 +126,56 @@ unless ($Attachments) {
$attachments->Columns( qw( Id Filename ContentType Headers Subject Parent ContentEncoding ContentType TransactionId) );
$Attachments = $attachments->ItemsArrayRef();
}
+my $titlebar_commands = '&nbsp;';
+my @DisplayHeaders=qw ( _all);
-my $titlebar_commands='&nbsp;';
+if ( $Transaction->Type =~ /EmailRecord$/ ) {
+ @DisplayHeaders = qw(To Cc Bcc);
-# If the transaction has anything attached to it at all
-if ($Attachments->[0] && $ShowTitleBarCommands) {
- if ($Ticket->CurrentUserHasRight('ReplyToTicket')) {
- $titlebar_commands .=
- "[<a href=\"".$UpdatePath."?id=".
- $Transaction->Ticket . "&QuoteTransaction=".$Transaction->Id.
- "&Action=Respond\">". loc('Reply') ."</a>]&nbsp;";
- }
- if ($Ticket->CurrentUserHasRight('CommentOnTicket')) {
- $titlebar_commands .=
- "[<a href=\"".$UpdatePath."?id=".$Transaction->Ticket.
- "&QuoteTransaction=".$Transaction->Id.
- "&Action=Comment\">". loc('Comment') ."</a>]";
- }
+ $titlebar_commands .=
+ "[<a target=\"_blank\" href=\"$EmailRecordPath?id="
+ . $Transaction->Ticket
+ . "&Transaction="
+ . $Transaction->Id
+ . "&Attachment="
+ . ( $Transaction->Attachments->First
+ && $Transaction->Attachments->First->Id )
+
+ . '">' . loc('Show') . "</a>]&nbsp;";
+ $ShowBody = 0;
}
+
+# If the transaction has anything attached to it at all
+else {
+
+ unless ( $ShowHeaders ) {
+ @DisplayHeaders = qw(To From RT-Send-Cc Cc Bcc Date Subject);
+ }
+
+ if ( $Attachments->[0] && $ShowTitleBarCommands ) {
+ if ( $Transaction->TicketObj->CurrentUserHasRight('ReplyToTicket')
+ or $Transaction->TicketObj->CurrentUserHasRight('ModifyTicket')) {
+ $titlebar_commands .=
+ "[<a href=\"".$UpdatePath."?id="
+ . $Transaction->Ticket
+ . "&QuoteTransaction="
+ . $Transaction->Id
+ . "&Action=Respond\">"
+ . loc('Reply')
+ . "</a>]&nbsp;";
+ }
+ if ( $Transaction->TicketObj->CurrentUserHasRight('CommentOnTicket')
+ or $Transaction->TicketObj->CurrentUserHasRight('ModifyTicket')) {
+ $titlebar_commands .=
+ "[<a href=\"".$UpdatePath."?id="
+ . $Transaction->Ticket
+ . "&QuoteTransaction="
+ . $Transaction->Id
+ . "&Action=Comment\">"
+ . loc('Comment') . "</a>]";
+ }
+ }
+}
</%INIT>
diff --git a/rt/html/Ticket/Elements/ShowTransactionAttachments b/rt/html/Ticket/Elements/ShowTransactionAttachments
new file mode 100644
index 000000000..b01586deb
--- /dev/null
+++ b/rt/html/Ticket/Elements/ShowTransactionAttachments
@@ -0,0 +1,196 @@
+%# {{{ BEGIN BPS TAGGED BLOCK
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
+<%perl>
+# Find all the attachments which have parent $Parent
+# For each of these attachments
+foreach my $message ( grep { $_->Parent == $Parent } @$Attachments ) {
+
+ # {{{ show the headers
+ my $headers = $message->Headers;
+ chomp $headers;
+
+ # localize the common headers (like 'Subject:'), too.
+ $headers =~ s/^([^:]+)(?=:)/loc($1)/em;
+ $m->comp(
+ 'ShowMessageHeaders',
+ Headers => $headers,
+ Transaction => $Transaction,
+ DisplayHeaders => \@DisplayHeaders
+ );
+
+ # }}}
+ # {{{ if there's any size at all, show the download link
+ my $size = $message->ContentLength;
+ if ($size) {
+
+</%perl>
+<div class="downloadattachment">
+<%perl>
+
+ # show a download link
+ if ( $size > 1024 ) {
+ $size = loc( "[_1]k", int( $size / 102.4 ) / 10 );
+ }
+ else {
+ $size = loc( "[_1]b", $size );
+ }
+
+</%PERL>
+<A HREF="<%$AttachPath%>/<%$Transaction->Id%>/<%$message->Id%>/<%$message->Filename | u%>"><&|/l&>Download</&><%$message->Filename || loc('(untitled)') %></a>
+<div class="downloadcontenttype">
+<%$message->ContentType%> <% $size %>
+</div>
+</div>
+%}
+
+% # }}}
+<div class="messagebody">
+<%perl>
+# {{{ if it's got content-disposition inline, show it inline
+ my $content;
+
+ # If it's text
+ if ( $message->ContentType =~ m{^(text|message)}i ) {
+
+ if (
+
+ # it's a toplevel object
+ !$ParentObj
+
+ # or its parent isn't a multipart alternative
+ || ( $ParentObj->ContentType !~ m{^multipart/alternative$}i )
+
+ # or it's of our prefered alterative type
+ || (
+ (
+ $RT::PreferRichText
+ && ( $message->ContentType =~ m{^text/(?:html|enriched)$} )
+ )
+ || ( !$RT::PreferRichText
+ && ( $message->ContentType !~ m{^text/(?:html|enriched)$} )
+ )
+ )
+ )
+ {
+
+ if ( $AttachmentContent->{ $message->id } ) {
+ $content = $AttachmentContent->{ $message->id }->Content;
+ }
+ else {
+ $content = $message->Content;
+ }
+
+ # if it's a text/html clean the body and show it
+ if ( $message->ContentType =~ m{^text/(?:html|enriched)$}i ) {
+ $content =
+ $m->comp( '/Elements/ScrubHTML', Content => $content );
+ $m->out( $content );
+ }
+
+ # if it's a text/plain show the body
+ elsif ( $message->ContentType =~ m{^(text|message|text)}i ) {
+
+ eval { $content = Text::Quoted::extract($content); };
+ if ($@) { 1; }
+
+ $m->comp(
+ 'ShowMessageStanza',
+ Depth => 0,
+ Message => $content,
+ Transaction => $Transaction
+ );
+ }
+ }
+
+ }
+ # if it's an image, show it as an image
+ elsif ( $message->ContentType =~ /^image\//i ) {
+ $m->out('<img src="'
+ . $AttachPath . '/'
+ . $Transaction->Id . '/'
+ . $message->Id
+ . '/">' );
+ }
+
+
+ # }}}
+
+ $m->comp( 'ShowTransactionAttachments', %ARGS,
+ Parent => $message->id,
+ ParentObj => $message );
+
+
+}
+</%PERL>
+</div>
+<%ARGS>
+$Ticket => undef
+$Transaction => undef
+$ShowHeaders => 0
+$Collapsed => undef
+$ShowTitleBarCommands => 1
+$RowNum => 1
+$AttachPath => $RT::WebPath."/Ticket/Attachment"
+$UpdatePath => $RT::WebPath."/Ticket/Update.html"
+$EmailRecordPath => $RT::WebPath."/Ticket/ShowEmailRecord.html"
+$Attachments => undef
+$AttachmentContent => undef
+$ShowBody => 1
+$Parent => 0
+$ParentObj => 0
+</%ARGS>
+<%INIT>
+my @DisplayHeaders=qw( _all);
+
+if ( $Transaction->Type =~ /EmailRecord$/ ) {
+ @DisplayHeaders = qw(To Cc Bcc);
+}
+
+# If the transaction has anything attached to it at all
+elsif (!$ShowHeaders) {
+ @DisplayHeaders = qw(To From RT-Send-Cc Cc Bcc Date Subject);
+}
+</%INIT>
diff --git a/rt/html/Ticket/Elements/ShowUserEntry b/rt/html/Ticket/Elements/ShowUserEntry
new file mode 100644
index 000000000..38473fff9
--- /dev/null
+++ b/rt/html/Ticket/Elements/ShowUserEntry
@@ -0,0 +1,55 @@
+%# {{{ BEGIN BPS TAGGED BLOCK
+%#
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
+%#
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
+%#
+%# This work is made available to you under the terms of Version 2 of
+%# the GNU General Public License. A copy of that license should have
+%# been provided with this software, but in any event can be snarfed
+%# from www.gnu.org.
+%#
+%# This work is distributed in the hope that it will be useful, but
+%# WITHOUT ANY WARRANTY; without even the implied warranty of
+%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+%# General Public License for more details.
+%#
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
+%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
+%#
+%# }}} END BPS TAGGED BLOCK
+%# Released under the terms of version 2 of the GNU Public License
+
+<%$User->Name%>
+% if ($User->EmailAddress && $User->EmailAddress ne $User->Name) {
+&lt;<%$User->EmailAddress%>&gt;
+% }
+
+<%ARGS>
+$User => undef
+</%ARGS> \ No newline at end of file
diff --git a/rt/html/Ticket/Elements/Tabs b/rt/html/Ticket/Elements/Tabs
index cba45df91..4f17d1024 100644
--- a/rt/html/Ticket/Elements/Tabs
+++ b/rt/html/Ticket/Elements/Tabs
@@ -1,8 +1,14 @@
-%# BEGIN LICENSE BLOCK
+%# {{{ BEGIN BPS TAGGED BLOCK
%#
-%# Copyright (c) 1996-2003 Jesse Vincent <jesse@bestpractical.com>
+%# COPYRIGHT:
+%#
+%# This software is Copyright (c) 1996-2004 Best Practical Solutions, LLC
+%# <jesse@bestpractical.com>
%#
-%# (Except where explictly superceded by other copyright notices)
+%# (Except where explicitly superseded by other copyright notices)
+%#
+%#
+%# LICENSE:
%#
%# This work is made available to you under the terms of Version 2 of
%# the GNU General Public License. A copy of that license should have
@@ -14,13 +20,29 @@
%# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
%# General Public License for more details.
%#
-%# Unless otherwise specified, all modifications, corrections or
-%# extensions to this work which alter its source code become the
-%# property of Best Practical Solutions, LLC when submitted for
-%# inclusion in the work.
+%# You should have received a copy of the GNU General Public License
+%# along with this program; if not, write to the Free Software
+%# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+%#
+%#
+%# CONTRIBUTION SUBMISSION POLICY:
+%#
+%# (The following paragraph is not intended to limit the rights granted
+%# to you to modify and distribute this software under the terms of
+%# the GNU General Public License and is only of importance to you if
+%# you choose to contribute your changes and enhancements to the
+%# community by submitting them to Best Practical Solutions, LLC.)
%#
+%# By intentionally submitting any modifications, corrections or
+%# derivatives to this work, or any other work intended for use with
+%# Request Tracker, to Best Practical Solutions, LLC, you confirm that
+%# you are the copyright holder for those contributions and you grant
+%# Best Practical Solutions, LLC a nonexclusive, worldwide, irrevocable,
+%# royalty-free, perpetual, license to use, copy, create derivative
+%# works based on those contributions, and sublicense and distribute
+%# those contributions and any derivatives thereof.
%#
-%# END LICENSE BLOCK
+%# }}} END BPS TAGGED BLOCK
<& /Elements/Callback, Ticket => $Ticket, actions=> $actions, tabs => $tabs, %ARGS &>
<& /Elements/Tabs,
tabs => $tabs,
@@ -31,12 +53,8 @@
<%INIT>
my $tabs = {};
-my $current_toptab = "Search/Listing.html",
- my $searchtabs = { new => { title => loc('New Search'),
- path => 'Search/Listing.html?ClearRestrictions=1'}
-
-
-} ;
+my $current_toptab = "Search/Build.html",
+my $searchtabs = {};
my $actions;
if ( $Ticket) {
@@ -55,7 +73,7 @@ if ( defined $session{'tickets'} ) {
$session{'tickets'}->PrepForSerialization();
}
- # Don't $current_toptab = display prev links if we're on the first ticket
+ # Don't display prev links if we're on the first ticket
if ($item_map->{$Ticket->Id}->{prev}) {
$searchtabs->{'_a'} = {
class => "nav",
@@ -160,10 +178,33 @@ if ( $Ticket->CurrentUserHasRight('ModifyTicket')
};
}
}
-$tabs->{"g"} = { path => 'Search/Listing.html',
- title => loc('Search'),
- separator => 1,
- subtabs => $searchtabs };
+
+my $args = "?" . $m->comp(
+ '/Elements/QueryString',
+ Query => $ARGS{'Query'} || $session{'CurrentSearchHash'}->{'Query'},
+ Format => $ARGS{'Format'} || $session{'CurrentSearchHash'}->{'Format'},
+ OrderBy => $ARGS{'OrderBy'} || $session{'CurrentSearchHash'}->{'OrderBy'},
+ Order => $ARGS{'Order'} || $session{'CurrentSearchHash'}->{'Order'},
+ Rows => $ARGS{'Rows'},
+ ) if ($ARGS{'Query'} or $session{'CurrentSearchHash'}->{'Query'});
+
+$tabs->{"f"} = { path => "Search/Build.html?NewQuery=1",
+ title => loc('New Query')};
+$tabs->{"g"} = { path => "Search/Build.html$args",
+ title => loc('Query Builder')};
+$tabs->{"h"} = { path => "Search/Edit.html$args",
+ title => loc('Advanced'),
+ separator => 1 };
+if (defined $session{'tickets'} and $session{'tickets'}->Count) {
+ $tabs->{"i"} = { path => "Search/Results.html$args",
+ title => loc('Show Results'),
+ separator => 1,
+ subtabs => $searchtabs };
+ if ($current_tab =~ "Search/Results.html") {
+ $current_tab = "Search/Results.html$args";
+ }
+}
+
</%INIT>