</td>
</tr>
{/if}
- {/foreach}
{/if}
- {if $isShowTax && {contribution.tax_amount|boolean}}
+
+ {if {event.is_public|boolean}}
<tr>
- <td {$labelStyle}>
- {ts}Amount Before Tax:{/ts}
+ <td colspan="2" {$valueStyle}>
+ {capture assign=icalFeed}{crmURL p='civicrm/event/ical' q="reset=1&id={event.id}" h=0 a=1 fe=1}{/capture}
+ <a href="{$icalFeed}">{ts}Download iCalendar entry for this event.{/ts}</a>
</td>
- <td {$valueStyle}>
- {if $isPrimary}{contribution.tax_exclusive_amount}{else}{$participant.totals.total_amount_exclusive|crmMoney}{/if}
+ </tr>
+ <tr>
+ <td colspan="2" {$valueStyle}>
+ {capture assign=gCalendar}{crmURL p='civicrm/event/ical' q="gCalendar=1&reset=1&id={event.id}" h=0 a=1 fe=1}{/capture}
+ <a href="{$gCalendar}">{ts}Add event to Google Calendar{/ts}</a>
</td>
- </tr>
+ </tr>
+ {/if}
- {if !$isPrimary}
- {* Use the participant specific tax rate breakdown *}
- {assign var=taxRateBreakdown value=$participant.tax_rate_breakdown}
+ {if {event.is_share|boolean}}
+ <tr>
+ <td colspan="2" {$valueStyle}>
+ {capture assign=eventUrl}{crmURL p='civicrm/event/info' q="id={event.id}&reset=1" a=true fe=1 h=1}{/capture}
+ {include file="CRM/common/SocialNetwork.tpl" emailMode=true url=$eventUrl pageURL=$eventUrl title='{event.title}'}
+ </td>
+ </tr>
+ {/if}
+ {if !empty($payer.name)}
+ <tr>
+ <th {$headerStyle}>
+ {ts}You were registered by:{/ts}
+ </th>
+ </tr>
+ <tr>
+ <td colspan="2" {$valueStyle}>
+ {$payer.name}
+ </td>
+ </tr>
+ {/if}
+ {if {event.is_monetary|boolean} and empty($isRequireApproval)}
+ <tr>
+ <th {$headerStyle}>
+ {event.fee_label}
+ </th>
+ </tr>
+ {if $isShowLineItems}
+ {foreach from=$participants key=index item=currentParticipant}
+ {if $isPrimary || {participant.id} === $currentParticipant.id}
+ {if $isPrimary && ($participants|@count > 1)} {* Header for multi participant registration cases. *}
+ <tr>
+ <td colspan="2" {$labelStyle}>
+ {$currentParticipant.contact.display_name}
+ </td>
+ </tr>
+ {/if}
+ <tr>
+ <td colspan="2" {$valueStyle}>
+ <table>
+ <tr>
+ <th>{ts}Item{/ts}</th>
+ <th>{ts}Qty{/ts}</th>
+ <th>{ts}Each{/ts}</th>
+ {if $isShowTax && {contribution.tax_amount|boolean}}
+ <th>{ts}Subtotal{/ts}</th>
+ <th>{ts}Tax Rate{/ts}</th>
+ <th>{ts}Tax Amount{/ts}</th>
+ {/if}
+ <th>{ts}Total{/ts}</th>
+ {if !empty($pricesetFieldsCount)}
+ <th>{ts}Total Participants{/ts}</th>
+ {/if}
+ </tr>
+ {foreach from=$currentParticipant.line_items item=line}
+ <tr>
+ <td {$tdfirstStyle}>{$line.title}</td>
+ <td {$tdStyle} align="middle">{$line.qty}</td>
+ <td {$tdStyle}>{$line.unit_price|crmMoney:$currency}</td>
+ {if $isShowTax && {contribution.tax_amount|boolean}}
+ <td>{$line.line_total|crmMoney:$currency}</td>
+ {if $line.tax_rate || $line.tax_amount != ""}
+ <td>{$line.tax_rate|string_format:"%.2f"}%</td>
+ <td>{$line.tax_amount|crmMoney:$currency}</td>
+ {else}
+ <td></td>
+ <td></td>
+ {/if}
+ {/if}
+ <td {$tdStyle}>
+ {$line.line_total+$line.tax_amount|crmMoney:$currency}
+ </td>
+ {if !empty($pricesetFieldsCount)}
+ <td {$tdStyle}>{$line.participant_count}</td>
+ {/if}
+ </tr>
+ {/foreach}
+ {if $isShowTax && $isPrimary && ($participants|@count > 1)}
+ <tr {$participantTotalStyle}>
+ <td colspan=3>{ts 1=$currentParticipant.contact.display_name}Total for %1{/ts}</td>
+ <td colspan=2>{$currentParticipant.totals.total_amount_exclusive|crmMoney}</td>
+ <td colspan=1>{$currentParticipant.totals.tax_amount|crmMoney}</td>
+ <td colspan=2>{$currentParticipant.totals.total_amount_inclusive|crmMoney}</td>
+ </tr>
+ {/if}
+ </table>
+ </td>
+ </tr>
+ {/if}
+ {/foreach}
{/if}
- {foreach from=$taxRateBreakdown item=taxDetail key=taxRate}
+ {if !$isShowLineItems}
+ {foreach from=$participants key=index item=currentParticipant}
+ {if $isPrimary || {participant.id} === $currentParticipant.id}
+ {foreach from=$currentParticipant.line_items key=index item=currentLineItem}
+ <tr>
+ <td {$valueStyle}>
+ {$currentLineItem.label}{if $isPrimary && ($participants|@count > 1)} - {$currentParticipant.contact.display_name}{/if}
+ </td>
+ <td {$valueStyle}>
+ {$currentLineItem.line_total|crmMoney:$currency}
+ </td>
+ </tr>
+ {/foreach}
+ {/if}
+ {/foreach}
+ {/if}
+ {if $isShowTax && {contribution.tax_amount|boolean}}
<tr>
- <td {$labelStyle}>{if $taxRate == 0}{ts}No{/ts} {$taxTerm}{else}{$taxTerm} {$taxDetail.percentage}%{/if}</td>
- <td {$valueStyle}>{$taxDetail.amount|crmMoney:'{contribution.currency}'}</td>
+ <td {$labelStyle}>
+ {ts}Amount Before Tax:{/ts}
+ </td>
+ <td {$valueStyle}>
+ {if $isPrimary}{contribution.tax_exclusive_amount}{else}{$participant.totals.total_amount_exclusive|crmMoney}{/if}
+ </td>
</tr>
- {/foreach}
- {/if}
-
- {if !empty($amounts) && empty($lineItem)}
- {foreach from=$amounts item=amnt key=level}
- <tr>
- <td colspan="2" {$valueStyle}>
- {$amnt.amount|crmMoney:$currency} {$amnt.label}
- </td>
- </tr>
- {/foreach}
- {/if}
-
- {if $isShowTax && {contribution.tax_amount|boolean}}
- <tr>
- <td {$labelStyle}>
- {ts}Total Tax Amount{/ts}
- </td>
- <td {$valueStyle}>
- {if $isPrimary}{contribution.tax_amount}{else}{$participant.totals.tax_amount|crmMoney}{/if}
- </td>
- </tr>
- {/if}
- {if $isPrimary}
- <tr>
- <td {$labelStyle}>
- {ts}Total Amount{/ts}
- </td>
- <td {$valueStyle}>
- {contribution.total_amount} {if !empty($hookDiscount.message)}({$hookDiscount.message}){/if}
- </td>
- </tr>
- {if !empty($pricesetFieldsCount) }
- <tr>
- <td {$labelStyle}>
- {ts}Total Participants{/ts}</td>
- <td {$valueStyle}>
- {assign var="count" value= 0}
- {foreach from=$lineItem item=pcount}
- {assign var="lineItemCount" value=0}
- {if $pcount neq 'skip'}
- {foreach from=$pcount item=p_count}
- {assign var="lineItemCount" value=$lineItemCount+$p_count.participant_count}
- {/foreach}
- {if $lineItemCount < 1 }
- {assign var="lineItemCount" value=1}
- {/if}
- {assign var="count" value=$count+$lineItemCount}
- {/if}
- {/foreach}
- {$count}
- </td> </tr>
- {/if}
-
- {if $register_date}
- <tr>
- <td {$labelStyle}>
- {ts}Registration Date{/ts}
- </td>
- <td {$valueStyle}>
- {$register_date|crmDate}
- </td>
- </tr>
- {/if}
-
- {if !empty($receive_date)}
- <tr>
- <td {$labelStyle}>
- {ts}Transaction Date{/ts}
- </td>
- <td {$valueStyle}>
- {$receive_date|crmDate}
- </td>
- </tr>
- {/if}
-
- {if !empty($financialTypeName)}
- <tr>
- <td {$labelStyle}>
- {ts}Financial Type{/ts}
- </td>
- <td {$valueStyle}>
- {$financialTypeName}
- </td>
- </tr>
- {/if}
+ {if !$isPrimary}
+ {* Use the participant specific tax rate breakdown *}
+ {assign var=taxRateBreakdown value=$participant.tax_rate_breakdown}
+ {/if}
+ {foreach from=$taxRateBreakdown item=taxDetail key=taxRate}
+ <tr>
+ <td {$labelStyle}>{if $taxRate == 0}{ts}No{/ts} {$taxTerm}{else}{$taxTerm} {$taxDetail.percentage}%{/if}</td>
+ <td {$valueStyle}>{$taxDetail.amount|crmMoney:'{contribution.currency}'}</td>
+ </tr>
+ {/foreach}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Total Tax Amount{/ts}
+ </td>
+ <td {$valueStyle}>
+ {if $isPrimary}{contribution.tax_amount}{else}{$participant.totals.tax_amount|crmMoney}{/if}
+ </td>
+ </tr>
+ {/if}
+ {if $isPrimary}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Total Amount{/ts}
+ </td>
+ <td {$valueStyle}>
+ {contribution.total_amount} {if !empty($hookDiscount.message)}({$hookDiscount.message}){/if}
+ </td>
+ </tr>
+ {if !empty($pricesetFieldsCount)}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Total Participants{/ts}</td>
+ <td {$valueStyle}>
+ {assign var="count" value= 0}
+ {foreach from=$lineItem item=pcount}
+ {assign var="lineItemCount" value=0}
+ {if $pcount neq 'skip'}
+ {foreach from=$pcount item=p_count}
+ {assign var="lineItemCount" value=$lineItemCount+$p_count.participant_count}
+ {/foreach}
+ {if $lineItemCount < 1}
+ {assign var="lineItemCount" value=1}
+ {/if}
+ {assign var="count" value=$count+$lineItemCount}
+ {/if}
+ {/foreach}
+ {$count}
+ </td>
+ </tr>
+ {/if}
+
+ {if {participant.register_date|boolean}}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Registration Date{/ts}
+ </td>
+ <td {$valueStyle}>
+ {participant.register_date}
+ </td>
+ </tr>
+ {/if}
+
+ {if !empty($receive_date)}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Transaction Date{/ts}
+ </td>
+ <td {$valueStyle}>
+ {$receive_date|crmDate}
+ </td>
+ </tr>
+ {/if}
+
+ {if !empty($financialTypeName)}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Financial Type{/ts}
+ </td>
+ <td {$valueStyle}>
+ {$financialTypeName}
+ </td>
+ </tr>
+ {/if}
+
+ {if !empty($trxn_id)}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Transaction #{/ts}
+ </td>
+ <td {$valueStyle}>
+ {$trxn_id}
+ </td>
+ </tr>
+ {/if}
+
+ {if {contribution.payment_instrument_id|boolean} && {contribution.paid_amount|boolean}}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Paid By{/ts}
+ </td>
+ <td {$valueStyle}>
+ {contribution.payment_instrument_id:label}
+ </td>
+ </tr>
+ {/if}
+
+ {if !empty($checkNumber)}
+ <tr>
+ <td {$labelStyle}>
+ {ts}Check Number{/ts}
+ </td>
+ <td {$valueStyle}>
+ {$checkNumber}
+ </td>
+ </tr>
+ {/if}
+
+ {if !empty($billingName)}
+ <tr>
+ <th {$headerStyle}>
+ {ts}Billing Name and Address{/ts}
+ </th>
+ </tr>
+ <tr>
+ <td colspan="2" {$valueStyle}>
+ {$billingName}<br/>
+ {$address|nl2br}
+ </td>
+ </tr>
+ {/if}
+
+ {if !empty($credit_card_type)}
+ <tr>
+ <th {$headerStyle}>
+ {ts}Credit Card Information{/ts}
+ </th>
+ </tr>
+ <tr>
+ <td colspan="2" {$valueStyle}>
+ {$credit_card_type}<br/>
+ {$credit_card_number}<br/>
+ {ts}Expires{/ts}: {$credit_card_exp_date|truncate:7:''|crmDate}
+ </td>
+ </tr>
+ {/if}
+ {/if}
- {if !empty($trxn_id)}
- <tr>
- <td {$labelStyle}>
- {ts}Transaction #{/ts}
- </td>
- <td {$valueStyle}>
- {$trxn_id}
- </td>
- </tr>
- {/if}
+ {/if} {* End of conditional section for Paid events *}
- {if !empty($paidBy)}
- <tr>
- <td {$labelStyle}>
- {ts}Paid By{/ts}
- </td>
- <td {$valueStyle}>
- {$paidBy}
- </td>
- </tr>
- {/if}
+ {if !empty($customPre)}
+ {foreach from=$customPre item=customPr key=i}
+ <tr>
+ <th {$headerStyle}>{$customPre_grouptitle.$i}</th>
+ </tr>
+ {foreach from=$customPr item=customValue key=customName}
+ <tr>
+ <td {$labelStyle}>{$customName}</td>
+ <td {$valueStyle}>{$customValue}</td>
+ </tr>
+ {/foreach}
+ {/foreach}
+ {/if}
- {if !empty($checkNumber)}
- <tr>
- <td {$labelStyle}>
- {ts}Check Number{/ts}
- </td>
- <td {$valueStyle}>
- {$checkNumber}
- </td>
- </tr>
- {/if}
+ {if !empty($customPost)}
+ {foreach from=$customPost item=customPos key=j}
+ <tr>
+ <th {$headerStyle}>{$customPost_grouptitle.$j}</th>
+ </tr>
+ {foreach from=$customPos item=customValue key=customName}
+ <tr>
+ <td {$labelStyle}>{$customName}</td>
+ <td {$valueStyle}>{$customValue}</td>
+ </tr>
+ {/foreach}
+ {/foreach}
+ {/if}
- {if !empty($billingName)}
- <tr>
- <th {$headerStyle}>
- {ts}Billing Name and Address{/ts}
- </th>
- </tr>
- <tr>
- <td colspan="2" {$valueStyle}>
- {$billingName}<br />
- {$address|nl2br}
- </td>
- </tr>
- {/if}
+ {if !empty($customProfile)}
+ {foreach from=$customProfile.profile item=eachParticipant key=participantID}
+ <tr>
+ <th {$headerStyle}>{ts 1=$participantID+2}Participant %1{/ts} </th>
+ </tr>
+ {foreach from=$eachParticipant item=eachProfile key=pid}
+ <tr>
+ <th {$headerStyle}>{$customProfile.title.$pid}</th>
+ </tr>
+ {foreach from=$eachProfile item=val key=field}
+ <tr>
+ {foreach from=$val item=v key=f}
+ <td {$labelStyle}>{$field}</td>
+ <td {$valueStyle}>{$v}</td>
+ {/foreach}
+ </tr>
+ {/foreach}
+ {/foreach}
+ {/foreach}
+ {/if}
- {if !empty($credit_card_type)}
+ </table>
+ {if !empty($event.allow_selfcancelxfer)}
<tr>
- <th {$headerStyle}>
- {ts}Credit Card Information{/ts}
- </th>
+ <td colspan="2" {$valueStyle}>
+ {ts 1=$selfcancelxfer_time 2=$selfservice_preposition}You may transfer your registration to another participant or cancel your registration up to %1 hours %2 the event.{/ts} {if !empty($totalAmount)}{ts}Cancellations are not refundable.{/ts}{/if}<br/>
- {capture assign=selfService}{crmURL p='civicrm/event/selfsvcupdate' q="reset=1&pid=`{participant.id}`&{contact.checksum}" h=0 a=1 fe=1}{/capture}
++ {capture assign=selfService}{crmURL p='civicrm/event/selfsvcupdate' q="reset=1&pid={participant.id}&{contact.checksum}" h=0 a=1 fe=1}{/capture}
+ <a href="{$selfService}">{ts}Click here to transfer or cancel your registration.{/ts}</a>
+ </td>
</tr>
- <tr>
- <td colspan="2" {$valueStyle}>
- {$credit_card_type}<br />
- {$credit_card_number}<br />
- {ts}Expires{/ts}: {$credit_card_exp_date|truncate:7:''|crmDate}
- </td>
- </tr>
- {/if}
-
{/if}
-
- {/if} {* End of conditional section for Paid events *}
-
-
-{if !empty($customPre)}
-{foreach from=$customPre item=customPr key=i}
- <tr> <th {$headerStyle}>{$customPre_grouptitle.$i}</th></tr>
- {foreach from=$customPr item=customValue key=customName}
- <tr>
- <td {$labelStyle}>{$customName}</td>
- <td {$valueStyle}>{$customValue}</td>
- </tr>
- {/foreach}
-{/foreach}
-{/if}
-
-{if !empty($customPost)}
-{foreach from=$customPost item=customPos key=j}
- <tr> <th {$headerStyle}>{$customPost_grouptitle.$j}</th></tr>
- {foreach from=$customPos item=customValue key=customName}
- <tr>
- <td {$labelStyle}>{$customName}</td>
- <td {$valueStyle}>{$customValue}</td>
- </tr>
- {/foreach}
-{/foreach}
-{/if}
-
-{if !empty($customProfile)}
-{foreach from=$customProfile.profile item=eachParticipant key=participantID}
- <tr><th {$headerStyle}>{ts 1=$participantID+2}Participant %1{/ts} </th></tr>
- {foreach from=$eachParticipant item=eachProfile key=pid}
- <tr><th {$headerStyle}>{$customProfile.title.$pid}</th></tr>
- {foreach from=$eachProfile item=val key=field}
- <tr>{foreach from=$val item=v key=f}
- <td {$labelStyle}>{$field}</td>
- <td {$valueStyle}>{$v}</td>
- {/foreach}
- </tr>
- {/foreach}
-{/foreach}
-{/foreach}
-{/if}
-
- </table>
- {if !empty($event.allow_selfcancelxfer) }
- <tr>
- <td colspan="2" {$valueStyle}>
- {ts 1=$selfcancelxfer_time 2=$selfservice_preposition}You may transfer your registration to another participant or cancel your registration up to %1 hours %2 the event.{/ts} {if !empty($totalAmount)}{ts}Cancellations are not refundable.{/ts}{/if}<br />
- {capture assign=selfService}{crmURL p='civicrm/event/selfsvcupdate' q="reset=1&pid={participant.id}&{contact.checksum}" h=0 a=1 fe=1}{/capture}
- <a href="{$selfService}">{ts}Click here to transfer or cancel your registration.{/ts}</a>
- </td>
- </tr>
- {/if}
</table>
</body>