CRM-19429 - CiviEvent: don't imply participant status always sends emails
[civicrm-core.git] / templates / CRM / Event / Form / Task / Batch.tpl
CommitLineData
6a488035
TO
1{*
2 +--------------------------------------------------------------------+
2c4c49ca 3 | CiviCRM version 4.7 |
6a488035 4 +--------------------------------------------------------------------+
fa938177 5 | Copyright CiviCRM LLC (c) 2004-2016 |
6a488035
TO
6 +--------------------------------------------------------------------+
7 | This file is a part of CiviCRM. |
8 | |
9 | CiviCRM is free software; you can copy, modify, and distribute it |
10 | under the terms of the GNU Affero General Public License |
11 | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. |
12 | |
13 | CiviCRM is distributed in the hope that it will be useful, but |
14 | WITHOUT ANY WARRANTY; without even the implied warranty of |
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
16 | See the GNU Affero General Public License for more details. |
17 | |
18 | You should have received a copy of the GNU Affero General Public |
19 | License and the CiviCRM Licensing Exception along |
20 | with this program; if not, contact CiviCRM LLC |
21 | at info[AT]civicrm[DOT]org. If you have questions about the |
22 | GNU Affero General Public License or the licensing of CiviCRM, |
23 | see the CiviCRM license FAQ at http://civicrm.org/licensing |
24 +--------------------------------------------------------------------+
25*}
26<div class="batch-update crm-block crm-form-block crm-event-batch-form-block">
27<fieldset>
f72db5fa 28 <div class="help">
6a488035 29 {if $context EQ 'statusChange'} {* Update Participant Status task *}
f72db5fa 30 {ts}Update the status for each participant individually, OR change all statuses to:{/ts}
31 {$form.status_change.html} {help id="id-status_change"}
1aa1efef
AH
32 {if $status}
33 <div class="status">
34 {ts}Participants whose status is changed FROM Pending Pay Later TO Registered or Attended will receive a confirmation email and their payment status will be set to completed. If this is not you want to do, you can change their participant status by editing their event registration record directly.{/ts}
35 {if $notifyingStatuses}
36 <br />
37 {ts 1=$notifyingStatuses}Participants whose status is changed TO any of the following will be automatically notified via email: %1{/ts}
38 {/if}
39 </div>
40 {/if}
6a488035 41 {else}
3ea7ca33 42 {if $statusProfile EQ 1} {* Update Participant Status in batch task *}
f72db5fa 43 <div class="status">{$status}</div>
44 {/if}
45 {ts}Update field values for each participant as needed. To set a field to the same value for ALL rows, enter that value for the first participation and then click the
46 <strong>Copy icon</strong>
47 (next to the column title).{/ts}
6a488035 48 {/if}
d68d92a1 49 <p>{ts}Click <strong>Update Participant(s)</strong> below to save all your changes.{/ts}</p>
f72db5fa 50 </div>
6a488035
TO
51 <table class="crm-copy-fields">
52 <thead class="sticky">
53 <tr class="columnheader">
54 {foreach from=$readOnlyFields item=fTitle key=fName}
55 <td>{$fTitle}</td>
56 {/foreach}
57
58 <td>{ts}Event{/ts}</td>
59 {foreach from=$fields item=field key=fieldName}
60 <td><img src="{$config->resourceBase}i/copy.png" alt="{ts 1=$field.title}Click to copy %1 from row one to all rows.{/ts}" fname="{$field.name}" class="action-icon" title="{ts}Click here to copy the value in row one to ALL rows.{/ts}" />{$field.title}</td>
61 {/foreach}
62
63 </tr>
64 </thead>
65 {foreach from=$componentIds item=pid}
66 <tr class="{cycle values="odd-row,even-row"}" entity_id="{$pid}">
67 {foreach from=$readOnlyFields item=fTitle key=fName}
68 <td>{$contactDetails.$pid.$fName}</td>
69 {/foreach}
70
71 <td class="crm-event-title">{$details.$pid.title}</td>
72 {foreach from=$fields item=field key=fieldName}
73 {assign var=n value=$field.name}
217c192b 74 {if ( $n eq 'participant_register_date' ) }
6a488035
TO
75 <td class="compressed">{include file="CRM/common/jcalendar.tpl" elementName=$n elementIndex=$pid batchUpdate=1}</td>
76 {else}
77 <td class="compressed">{$form.field.$pid.$n.html}</td>
78 {/if}
79 {/foreach}
80 </tr>
81 {/foreach}
82 </tr>
83 <tr>
84 <td>&nbsp;</td>
85 <td>&nbsp;</td>
86 <td> {if $fields}{$form._qf_Batch_refresh.html}{/if}{include file="CRM/common/formButtons.tpl"}
87 </td>
88 </tr>
89 </table>
90
91</fieldset>
92</div>
93
94{if $context EQ 'statusChange'} {* Update Participant Status task *}
95{literal}
96<script type="text/javascript">
97/**
98 * Function to update participant status
99 */
3cc60a06 100CRM.$(function($) {
ae8f569f
CW
101 $('#status_change').change( function() {
102 if ( $(this).val() ) {
103 $('.crm-copy-fields [name^="field["][name*="[participant_status]"]').val( $(this).val() );
6a488035
TO
104 }
105 });
106
107});
108</script>
109{/literal}
110{/if}
111
112{*include batch copy js js file*}
113{include file="CRM/common/batchCopy.tpl"}