RT 4.0.13
[freeside.git] / rt / share / html / Ticket / Elements / ShowSimplifiedRecipients
index 590006b..a27375a 100644 (file)
@@ -2,7 +2,7 @@
 %#
 %# COPYRIGHT:
 %#
-%# This software is Copyright (c) 1996-2012 Best Practical Solutions, LLC
+%# This software is Copyright (c) 1996-2013 Best Practical Solutions, LLC
 %#                                          <sales@bestpractical.com>
 %#
 %# (Except where explicitly superseded by other copyright notices)
@@ -73,16 +73,17 @@ if ($Object->Rules) {
     }
 }
 my %recips;
+my %squelched = ProcessTransactionSquelching( \%ARGS );
 </%init>
 <&|/Widgets/TitleBox, title => loc('Recipients'), id => 'recipients' &>
 <table>
-<tr>
 % for my $type (qw(To Cc Bcc)) {
 %     next unless keys %{$headers{$type}};
+<tr>
 <td valign="top"><% $type %>:</td>
 <td valign="top">
 %     for my $addr (sort {$a->address cmp $b->address} values %{$headers{$type}}) {
-%         my $checked = 1;
+%         my $checked = not $squelched{$addr->address};
 %         $m->callback(CallbackName => 'BeforeAddress', Ticket => $TicketObj, Address => $addr, Type => $type, Checked => \$checked);
 %         $recips{$addr->address}++;
 <input type="checkbox" class="checkbox" name="TxnSendMailTo" <% $checked ? 'checked="checked"' : '' |n%> value="<%$addr->address%>" id="TxnSendMailTo-<% $addr->address %>-<% $recips{$addr->address} %>" />
@@ -92,6 +93,7 @@ my %recips;
 %     }
 </td></tr>
 % }
+% $m->callback( CallbackName => 'AfterRecipients', TicketObj => $TicketObj );
 </table>
 <i>(Uncheck boxes to disable notifications to the listed
 recipients. Does <b>not</b> change who will receive future