2 +--------------------------------------------------------------------+
3 | Copyright CiviCRM LLC. All rights reserved. |
5 | This work is published under the GNU AGPLv3 license with some |
6 | permitted exceptions and without any warranty. For full license |
7 | and copyright information, see https://civicrm.org/licensing |
8 +--------------------------------------------------------------------+
10 <div class="messages status no-popup">
11 <div class="icon inform-icon"></div>
12 {include file="CRM/Contribute/Form/Task.tpl"}
14 {if $selectedOutput ne 'email'}
16 {ts}You may choose to email invoice to contributors OR download a PDF file containing one invoice per page to your local computer by clicking <strong>Process Invoice(s)</strong> . Your browser may display the file for you automatically, or you may need to open it for printing using any PDF reader (such as Adobe® Reader).{/ts}
20 <table class="form-layout-compressed">
21 {if $selectedOutput ne 'email'}
23 <td class="label">{$form.output.email_invoice.label}</td>
24 <td>{$form.output.email_invoice.html}</td>
27 <tr id="selectEmailFrom" style="display: none" class="crm-contactEmail-form-block-fromEmailAddress crm-email-element">
28 <td class="label">{$form.from_email_address.label}</td>
29 <td>{$form.from_email_address.html} {help id="id-from_email" file="CRM/Contact/Form/Task/Email.hlp" isAdmin=$isAdmin}</td>
31 <tr class="crm-email-element">
32 <td class="label">{$form.email_comment.label}</td>
33 <td>{$form.email_comment.html}</td>
35 {if $selectedOutput ne 'email'}
37 <td class="label">{$form.output.pdf_invoice.label}</td>
38 <td>{$form.output.pdf_invoice.html}</td>
41 <tr class="crm-pdf-element">
42 <td class="label">{$form.pdf_format_id.label}</td>
43 <td>{$form.pdf_format_id.html}</td>
47 <div class="spacer"></div>
48 <div class="crm-submit-buttons">
53 <script type="text/javascript">
56 var o = $('input[name="output"]');
58 $('.crm-email-element').hide();
59 showhideEmailElements();
60 o.on('click', showhideEmailElements);
63 $('.crm-email-element').show();
66 function showhideEmailElements() {
67 if ($('input[name="output"]:checked').val() == 'email_invoice') {
68 $('.crm-email-element').show();
69 $('.crm-pdf-element').hide();
72 $('.crm-pdf-element').show();
73 $('.crm-email-element').hide();