[Rt-commit] rt branch, master, updated. rt-4.0.8-802-g86d0045
Alex Vandiver
alexmv at bestpractical.com
Mon Dec 3 16:48:06 EST 2012
The branch, master has been updated
via 86d004529d2a1680a4b41f5e0d6b7c23335a27d1 (commit)
via ef793e2f2e8f79ec61dff6f35b39d72a3210f0a5 (commit)
via d78cf7af01cd2076cab9fbd29859d9a525ce892c (commit)
via d6a574c7858162f0c63589b0fc8ea4def26201a1 (commit)
via 5a71507001924c500a8bad4e1fb040ea8b807190 (commit)
via e9d994b1093db7a6a559701d3c3d751181599517 (commit)
via c464ce54489318b132bee8711c3b96b442b80bd8 (commit)
via a52805c7e8fdf48cda95da92c6d655b39cbe3615 (commit)
via 0d8eacf36bd8428ff1b096bb79f3b10d085e32cd (commit)
via 920a2bd5e0ea397f0dffbbadd9066081fe6a3fad (commit)
via 775f4bd1fd8f78d18c9cce988b444bb04906d26e (commit)
via 4ebc502d2797f4b629af2a642b7067175ab4cd6d (commit)
via 1a3327ce992dd66cf6660c0454a6146cf3b39065 (commit)
via 8274e2b6b424b20f98f580884e227ee40a0f562a (commit)
via bb8310b8ac6b4c717461fab71df66ca6473aa818 (commit)
via 03b03897c2036a2d2b9b11b06761f147a85507fa (commit)
via 30a303dcca591cb149a86d072af57861b0b646ee (commit)
via ff7d41079af5bfc68e5e92fc83a45da911d9642d (commit)
via b03146927ad83b81d45b161c2dfbe5223739845f (commit)
via d7db2c3e1949e95f19f4779ce81fe631d83a5df1 (commit)
via 52ab3efd749e9842dea3498b82a92918f49bddf1 (commit)
via fa4a863a047c353c2081045b88dfe8ae12b80085 (commit)
via 0fb4b72ba301f7bdd9652713de8b988f189dd252 (commit)
via 8e16edbb146a8f7cdae5efde38658e2162623b23 (commit)
via 5052f08938b07e78b39e0e73c77eec01aa1d696f (commit)
via 905a5a46ed8c966b9e0e460225575bbfedc714d6 (commit)
via 7b88108f22ab54e33683a59b7b054ef9b4af5c58 (commit)
via 599fcda86772fb5797057cd3243ab1b9166b0d69 (commit)
via f0137c97671e79a77f21370db5de3b7662bedb9f (commit)
via 3b95e63c017a0d501a15ab2dd68b9ffc6a5d7de1 (commit)
via 8c7587ce431df8aabcaa14e6b8b8e86baaee3723 (commit)
via c86f1dd3a30be6cb2c8a04d14b9fed393aee2af9 (commit)
via be123049cb54cad09eebe0c9450b86a9d5f858c2 (commit)
via e15d19a61a56df5d5bb9a91eb5e75d6017bd3a3d (commit)
via 07cfcd7c6fe82b7b240bcd7e42e2cfc91d95e967 (commit)
via 8a5119dcf82d19a71e955b11ca4cfd1d11231870 (commit)
via 8ba0706c3d4150c1aa7288a33dc074ee00c5a02d (commit)
via ce92315730554fc1cf70f6fbf6c6a3d17f6a55f8 (commit)
via 2314c3d781052ef70cef5fc7483919a8583e81e9 (commit)
via bef38129137b169195301072a86cbedbdc5defff (commit)
via 0a5403e2af06b286ae3290133ed3ce64994560a0 (commit)
via fffa0856095b37dfbac3c1b25c391e65614ffa45 (commit)
via 2c8912e93cee9c67d9b552d1f0d8e4a79a135efa (commit)
from 9227a65159da7ac9e5620dbb52ea94f7614434e8 (commit)
Summary of changes:
docs/UPGRADING-4.2 | 8 +
etc/RT_Config.pm.in | 12 -
lib/RT/Attachment.pm | 30 +++
lib/RT/Record.pm | 162 +++++++++++-
lib/RT/Ticket.pm | 74 ++++++
lib/RT/Transaction.pm | 4 +-
share/html/Admin/Groups/History.html | 4 +-
share/html/Admin/Queues/History.html | 4 +-
share/html/Admin/Users/History.html | 4 +-
share/html/Approvals/Display.html | 2 +-
share/html/Approvals/Elements/Approve | 2 +-
share/html/Approvals/Elements/ShowDependency | 2 +-
share/html/Articles/Article/Elements/ShowHistory | 76 ------
share/html/Articles/Article/History.html | 19 +-
share/html/{Ticket => }/Elements/FoldStanzaJS | 0
share/html/{Ticket => }/Elements/ShowGnuPGStatus | 0
share/html/{Ticket => }/Elements/ShowHistory | 155 ++++++------
.../html/{Ticket => }/Elements/ShowMessageHeaders | 4 +-
share/html/{Ticket => }/Elements/ShowMessageStanza | 4 +-
share/html/Elements/ShowTransaction | 265 ++++++++++++++++++++
.../Elements/ShowTransactionAttachments | 67 ++---
share/html/Helpers/TicketHistory | 9 +-
share/html/NoAuth/css/aileron/msie.css | 2 +-
share/html/NoAuth/css/aileron/msie6.css | 2 +-
share/html/NoAuth/css/aileron/ticket.css | 242 ------------------
share/html/NoAuth/css/ballard/main.css | 1 -
share/html/NoAuth/css/ballard/msie.css | 2 +-
share/html/NoAuth/css/ballard/msie6.css | 2 +-
share/html/NoAuth/css/ballard/ticket.css | 278 ---------------------
.../css/{web2/ticket.css => base/history.css} | 152 +++--------
share/html/NoAuth/css/base/main.css | 1 +
share/html/NoAuth/css/base/ticket.css | 85 +++++++
share/html/NoAuth/css/print.css | 10 +-
share/html/NoAuth/css/web2/main.css | 1 -
share/html/NoAuth/css/web2/msie.css | 2 +-
share/html/NoAuth/css/web2/msie6.css | 2 +-
share/html/SelfService/Display.html | 13 +-
share/html/Ticket/Display.html | 19 +-
share/html/Ticket/Elements/FindAttachments | 95 -------
share/html/Ticket/Elements/FindTransactions | 72 ------
share/html/Ticket/Elements/LoadTextAttachments | 45 +---
share/html/Ticket/Elements/ShowAttachments | 32 +--
share/html/Ticket/Elements/ShowDates | 18 +-
share/html/Ticket/Elements/ShowTransaction | 240 ------------------
share/html/Ticket/History.html | 10 +-
share/html/m/ticket/show | 30 +--
t/web/ticket_txn_content.t | 4 +-
47 files changed, 827 insertions(+), 1440 deletions(-)
delete mode 100644 share/html/Articles/Article/Elements/ShowHistory
rename share/html/{Ticket => }/Elements/FoldStanzaJS (100%)
rename share/html/{Ticket => }/Elements/ShowGnuPGStatus (100%)
rename share/html/{Ticket => }/Elements/ShowHistory (61%)
rename share/html/{Ticket => }/Elements/ShowMessageHeaders (97%)
rename share/html/{Ticket => }/Elements/ShowMessageStanza (98%)
create mode 100644 share/html/Elements/ShowTransaction
rename share/html/{Ticket => }/Elements/ShowTransactionAttachments (82%)
delete mode 100644 share/html/NoAuth/css/ballard/ticket.css
rename share/html/NoAuth/css/{web2/ticket.css => base/history.css} (50%)
delete mode 100644 share/html/Ticket/Elements/FindAttachments
delete mode 100644 share/html/Ticket/Elements/FindTransactions
delete mode 100644 share/html/Ticket/Elements/ShowTransaction
- Log -----------------------------------------------------------------
commit 86d004529d2a1680a4b41f5e0d6b7c23335a27d1
Merge: 9227a65 ef793e2
Author: Alex Vandiver <alexmv at bestpractical.com>
Date: Mon Dec 3 15:59:05 2012 -0500
Merge branch '4.2/generic-history-rendering'
Conflicts:
docs/UPGRADING-4.2
lib/RT/Attachment.pm
diff --cc docs/UPGRADING-4.2
index 6ad8105,38e9f5b..43a9305
--- a/docs/UPGRADING-4.2
+++ b/docs/UPGRADING-4.2
@@@ -5,12 -5,10 +5,20 @@@ UPGRADING FROM RT 4.0.0 and greate
but an informational notice will be issued on server start telling you about
the rename. To avoid this you should set $LogToSTDERR instead.
+* The link direction and type maps are consolidated into RT::Link. If you
+ wrote local customizations or extensions utilizing %RT::Ticket::LINKDIRMAP,
+ %RT::Ticket::LINKTYPEMAP, RT::Ticket->LINKDIRMAP, RT::Ticket->LINKTYPEMAP, or
+ %RT::Record::LINKDIRMAP, you will need to switch to %RT::Link::DIRMAP and
+ %RT::Link::TYPEMAP.
+
+* $LinkTransactionsRun1Scrip is removed. If you were relying on this behaviour
+ (by setting it to 1), you should adjust your scrips to ignore one of the link
+ transactions.
++
+ * The $AttachmentUnits option was removed in preference of always displaying in
+ megabytes, kilobytes, or bytes as appropriate. The option was incompletely
+ implemented and controlled display in the attachments list but not history.
+
+ * MakeClicky handlers added via a callback are now passed an "object" key in
+ the parameter hash instead of "ticket". The object may be any RT::Record
+ subclass.
diff --cc lib/RT/Attachment.pm
index 41e2ee0,7322285..f0509a0
--- a/lib/RT/Attachment.pm
+++ b/lib/RT/Attachment.pm
@@@ -378,6 -396,89 +380,34 @@@ sub ContentLength
return $len;
}
+ =head2 FriendlyContentLength
+
+ Returns L</ContentLength> in bytes, kilobytes, or megabytes as most
+ appropriate. The size is suffixed with C<M>, C<k>, and C<b> and the returned
+ string is localized.
+
+ Returns the empty string if the L</ContentLength> is 0 or undefined.
+
+ =cut
+
+ sub FriendlyContentLength {
+ my $self = shift;
+ my $size = $self->ContentLength;
+ return '' unless $size;
+
+ my $res = '';
+ if ( $size > 1024*1024 ) {
+ $res = $self->loc( "[_1]M", int( $size / 1024 / 102.4 ) / 10 );
+ }
+ elsif ( $size > 1024 ) {
+ $res = $self->loc( "[_1]k", int( $size / 102.4 ) / 10 );
+ }
+ else {
+ $res = $self->loc( "[_1]b", $size );
+ }
+ return $res;
+ }
+
-=head2 Quote
-
-=cut
-
-sub Quote {
- my $self=shift;
- my %args=(Reply=>undef, # Prefilled reply (i.e. from the KB/FAQ system)
- @_);
-
- my ($quoted_content, $body, $headers);
- my $max=0;
-
- # TODO: Handle Multipart/Mixed (eventually fix the link in the
- # ShowHistory web template?)
- if (RT::I18N::IsTextualContentType($self->ContentType)) {
- $body=$self->Content;
-
- # Do we need any preformatting (wrapping, that is) of the message?
-
- # Remove quoted signature.
- $body =~ s/\n-- \n(.*)$//s;
-
- # What's the longest line like?
- foreach (split (/\n/,$body)) {
- $max=length if ( length > $max);
- }
-
- if ($max>76) {
- require Text::Wrapper;
- my $wrapper = Text::Wrapper->new
- (
- columns => 70,
- body_start => ($max > 70*3 ? ' ' : ''),
- par_start => ''
- );
- $body=$wrapper->wrap($body);
- }
-
- $body =~ s/^/> /gm;
-
- $body = '[' . $self->TransactionObj->CreatorObj->Name() . ' - ' . $self->TransactionObj->CreatedAsString()
- . "]:\n\n"
- . $body . "\n\n";
-
- } else {
- $body = "[Non-text message not quoted]\n\n";
- }
-
- $max=60 if $max<60;
- $max=70 if $max>78;
- $max+=2;
-
- return (\$body, $max);
-}
-
=head2 ContentAsMIME [Children => 1]
Returns MIME entity built from this attachment.
-----------------------------------------------------------------------
More information about the Rt-commit
mailing list