Merge pull request #15818 from colemanw/fields
[civicrm-core.git] / templates / CRM / Member / Form / Task / Batch.tpl
1 {*
2 +--------------------------------------------------------------------+
3 | Copyright CiviCRM LLC. All rights reserved. |
4 | |
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 +--------------------------------------------------------------------+
9 *}
10 <div class="crm-block crm-form-block crm-member-task-batch-form-block">
11 <div class="help">
12 {ts}Update field values for each member as needed. Click <strong>Update Memberships</strong> below to save all your changes. To set a field to the same value for ALL rows, enter that value for the first member and then click the <strong>Copy icon</strong> (next to the column title).{/ts}
13 </div>
14 <div class="crm-submit-buttons">
15 {if $fields}{$form._qf_Batch_refresh.html}{/if} &nbsp;{include file="CRM/common/formButtons.tpl" location="top"}
16 </div>
17 <table class="crm-copy-fields">
18 <thead class="sticky">
19 <tr class="columnheader">
20 {foreach from=$readOnlyFields item=fTitle key=fName}
21 <th>{$fTitle}</th>
22 {/foreach}
23
24 {foreach from=$fields item=field key=fieldName}
25 <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>
26 {/foreach}
27 </tr>
28 </thead>
29 {foreach from=$componentIds item=mid}
30 <tr class="{cycle values="odd-row,even-row"}" entity_id="{$mid}">
31
32 {foreach from=$readOnlyFields item=fTitle key=fName}
33 <td>{$contactDetails.$mid.$fName}</td>
34 {/foreach}
35
36 {foreach from=$fields item=field key=fieldName}
37 {assign var=n value=$field.name}
38 <td class="compressed">{$form.field.$mid.$n.html}</td>
39 {/foreach}
40 </tr>
41 {/foreach}
42 </tr>
43 </table>
44 <div class="crm-submit-buttons">
45 {if $fields}{$form._qf_Batch_refresh.html}{/if} &nbsp;{include file="CRM/common/formButtons.tpl" location="bottom"}
46 </div>
47 </div>
48
49 {*include batch copy js js file*}
50 {include file="CRM/common/batchCopy.tpl"}