[Rt-commit] rt branch, 4.2/scrips-correspond-selectall-checkbox, created. rt-4.2.6-19-ge162bee

Wallace Reis wreis at bestpractical.com
Fri Jul 18 15:51:14 EDT 2014


The branch, 4.2/scrips-correspond-selectall-checkbox has been created
        at  e162beeae689b63fb9f5d0d81429c5c06c172ef8 (commit)

- Log -----------------------------------------------------------------
commit e162beeae689b63fb9f5d0d81429c5c06c172ef8
Author: Wallace Reis <wreis at bestpractical.com>
Date:   Tue Jul 15 18:48:09 2014 -0300

    'Select All' checkbox for scrips correspondences/comments
    
    At ticket reply page, we have the option to select/deselect who in the
    list of people should receive a copy of the reply/comment. This aims to
    add an 'all' checkbox which can select/deselect all of them at once.

diff --git a/share/html/Ticket/Elements/PreviewScrips b/share/html/Ticket/Elements/PreviewScrips
index 973fe0d..51293ca 100644
--- a/share/html/Ticket/Elements/PreviewScrips
+++ b/share/html/Ticket/Elements/PreviewScrips
@@ -67,6 +67,14 @@ my %squelched = ProcessTransactionSquelching( \%ARGS );
 %                  map { [$_, $_->ActionObj->Action->To + $_->ActionObj->Action->Cc + $_->ActionObj->Action->Bcc] }
 %                  grep {$_->ActionObj->Action->isa('RT::Action::SendEmail')}
 %                  @{$Object->Scrips->Prepared};
+%   if ( grep {
+%          my $s = $_;
+%          my $action = $s->ActionObj->Action;
+%          scalar(map { $action->$_ } qw(To Cc Bcc))
+%        } @scrips ) {
+<input type="checkbox" name="TxnSendMailToAll" value="1" checked="checked" onclick="setCheckbox(this,'TxnSendMailTo')">
+<label for="TxnSendMailToAll"><b><% loc('All recipients') %></b></label><br />
+%   }
 %     for my $scrip (@scrips) {
           <b><% $scrip->Description || loc('Scrip #[_1]',$scrip->id) %></b><br />
           <&|/l, loc($scrip->ConditionObj->Name), loc($scrip->ActionObj->Name), loc($scrip->Template)&>[_1] [_2] with template [_3]</&>
diff --git a/share/html/Ticket/Elements/ShowSimplifiedRecipients b/share/html/Ticket/Elements/ShowSimplifiedRecipients
index bc662b2..cd82cbc 100644
--- a/share/html/Ticket/Elements/ShowSimplifiedRecipients
+++ b/share/html/Ticket/Elements/ShowSimplifiedRecipients
@@ -77,6 +77,14 @@ my %squelched = ProcessTransactionSquelching( \%ARGS );
 </%init>
 <&|/Widgets/TitleBox, title => loc('Recipients'), id => 'recipients' &>
 <table>
+%   if ( scalar(map { keys %{$headers{$_}} } qw(To Cc Bcc)) ) {
+<tr>
+<td>
+<input type="checkbox" name="TxnSendMailToAll" value="1" checked="checked" onclick="setCheckbox(this,'TxnSendMailTo')">
+<label for="TxnSendMailToAll"><b><% loc('All recipients') %></b></label>
+</td>
+</tr>
+% }
 % for my $type (qw(To Cc Bcc)) {
 %     next unless keys %{$headers{$type}};
 <tr>

-----------------------------------------------------------------------


More information about the rt-commit mailing list