Merge pull request #14394 from eileenmcnaughton/merge_get_conflicts
[civicrm-core.git] / xml / templates / message_templates / event_offline_receipt_html.tpl
CommitLineData
6a488035
TO
1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2<html xmlns="http://www.w3.org/1999/xhtml">
3<head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
5 <title></title>
6</head>
7<body>
8
9{capture assign=headerStyle}colspan="2" style="text-align: left; padding: 4px; border-bottom: 1px solid #999; background-color: #eee;"{/capture}
10{capture assign=labelStyle }style="padding: 4px; border-bottom: 1px solid #999; background-color: #f7f7f7;"{/capture}
11{capture assign=valueStyle }style="padding: 4px; border-bottom: 1px solid #999;"{/capture}
12
13<center>
14 <table width="620" border="0" cellpadding="0" cellspacing="0" id="crm-event_receipt" style="font-family: Arial, Verdana, sans-serif; text-align: left;">
15
16 <!-- BEGIN HEADER -->
17 <!-- You can add table row(s) here with logo or other header elements -->
18 <!-- END HEADER -->
19
20 <!-- BEGIN CONTENT -->
21
22 <tr>
23 <td>
9e26a129 24 <p>{contact.email_greeting}</p>
6a488035
TO
25
26 {if $event.confirm_email_text AND (not $isOnWaitlist AND not $isRequireApproval)}
27 <p>{$event.confirm_email_text|htmlize}</p>
28 {/if}
29
30 {if $isOnWaitlist}
31 <p>{ts}You have been added to the WAIT LIST for this event.{/ts}</p>
32 {if $isPrimary}
0865a4ed 33 <p>{ts}If space becomes available you will receive an email with a link to a web page where you can complete your registration.{/ts}</p>
6a488035
TO
34 {/if}
35 {elseif $isRequireApproval}
36 <p>{ts}Your registration has been submitted.{/ts}</p>
37 {if $isPrimary}
0865a4ed 38 <p>{ts}Once your registration has been reviewed, you will receive an email with a link to a web page where you can complete the registration process.{/ts}</p>
6a488035
TO
39 {/if}
40 {elseif $is_pay_later}
41 <p>{$pay_later_receipt}</p> {* FIXME: this might be text rather than HTML *}
42 {else}
43 <p>{ts}Please print this confirmation for your records.{/ts}</p>
44 {/if}
45
46 </td>
47 </tr>
48 <tr>
49 <td>
50 <table style="border: 1px solid #999; margin: 1em 0em 1em; border-collapse: collapse; width:100%;">
51 <tr>
52 <th {$headerStyle}>
53 {ts}Event Information and Location{/ts}
54 </th>
55 </tr>
56 <tr>
57 <td colspan="2" {$valueStyle}>
58 {$event.event_title}<br />
59 {$event.event_start_date|crmDate}{if $event.event_end_date}-{if $event.event_end_date|date_format:"%Y%m%d" == $event.event_start_date|date_format:"%Y%m%d"}{$event.event_end_date|crmDate:0:1}{else}{$event.event_end_date|crmDate}{/if}{/if}
60 </td>
61 </tr>
62
63 {if $event.participant_role neq 'Attendee' and $defaultRole}
64 <tr>
65 <td {$labelStyle}>
66 {ts}Participant Role{/ts}
67 </td>
68 <td {$valueStyle}>
69 {$event.participant_role}
70 </td>
71 </tr>
72 {/if}
73
74 {if $isShowLocation}
75 <tr>
76 <td colspan="2" {$valueStyle}>
d74c297f 77 {$location.address.1.display|nl2br}
6a488035
TO
78 </td>
79 </tr>
80 {/if}
81
82 {if $location.phone.1.phone || $location.email.1.email}
83 <tr>
84 <td colspan="2" {$labelStyle}>
85 {ts}Event Contacts:{/ts}
86 </td>
87 </tr>
88 {foreach from=$location.phone item=phone}
89 {if $phone.phone}
90 <tr>
91 <td {$labelStyle}>
92 {if $phone.phone_type}
93 {$phone.phone_type_display}
94 {else}
95 {ts}Phone{/ts}
96 {/if}
97 </td>
98 <td {$valueStyle}>
5d9ebb64 99 {$phone.phone} {if $phone.phone_ext}&nbsp;{ts}ext.{/ts} {$phone.phone_ext}{/if}
6a488035
TO
100 </td>
101 </tr>
102 {/if}
103 {/foreach}
104 {foreach from=$location.email item=eventEmail}
105 {if $eventEmail.email}
106 <tr>
107 <td {$labelStyle}>
108 {ts}Email{/ts}
109 </td>
110 <td {$valueStyle}>
111 {$eventEmail.email}
112 </td>
113 </tr>
114 {/if}
115 {/foreach}
116 {/if}
7f7fa13a
EM
117
118 {if $event.is_public}
278f760d
J
119 <tr>
120 <td colspan="2" {$valueStyle}>
121 {capture assign=icalFeed}{crmURL p='civicrm/event/ical' q="reset=1&id=`$event.id`" h=0 a=1 fe=1}{/capture}
122 <a href="{$icalFeed}">{ts}Download iCalendar File{/ts}</a>
123 </td>
124 </tr>
4de4dbe9 125 {/if}
7f7fa13a 126
6a488035
TO
127 {if $email}
128 <tr>
129 <th {$headerStyle}>
130 {ts}Registered Email{/ts}
131 </th>
132 </tr>
133 <tr>
134 <td colspan="2" {$valueStyle}>
135 {$email}
136 </td>
137 </tr>
138 {/if}
139
140
141 {if $event.is_monetary}
142
143 <tr>
144 <th {$headerStyle}>
145 {$event.fee_label}
146 </th>
147 </tr>
148
149 {if $lineItem}
150 {foreach from=$lineItem item=value key=priceset}
151 {if $value neq 'skip'}
152 {if $isPrimary}
153 {if $lineItem|@count GT 1} {* Header for multi participant registration cases. *}
154 <tr>
155 <td colspan="2" {$labelStyle}>
156 {ts 1=$priceset+1}Participant %1{/ts}
157 </td>
158 </tr>
159 {/if}
160 {/if}
161 <tr>
162 <td colspan="2" {$valueStyle}>
163 <table> {* FIXME: style this table so that it looks like the text version (justification, etc.) *}
164 <tr>
165 <th>{ts}Item{/ts}</th>
166 <th>{ts}Qty{/ts}</th>
167 <th>{ts}Each{/ts}</th>
7cf82823 168 {if $dataArray}
79d001a2
PB
169 <th>{ts}SubTotal{/ts}</th>
170 <th>{ts}Tax Rate{/ts}</th>
171 <th>{ts}Tax Amount{/ts}</th>
172 {/if}
6a488035 173 <th>{ts}Total{/ts}</th>
011aeb62 174 {if $pricesetFieldsCount }<th>{ts}Total Participants{/ts}</th>{/if}
6a488035
TO
175 </tr>
176 {foreach from=$value item=line}
177 <tr>
178 <td>
011aeb62 179 {if $line.html_type eq 'Text'}{$line.label}{else}{$line.field_title} - {$line.label}{/if} {if $line.description}<div>{$line.description|truncate:30:"..."}</div>{/if}
6a488035
TO
180 </td>
181 <td>
182 {$line.qty}
183 </td>
184 <td>
185 {$line.unit_price|crmMoney}
186 </td>
7cf82823 187 {if $dataArray}
79d001a2
PB
188 <td>
189 {$line.unit_price*$line.qty|crmMoney}
190 </td>
7cf82823
PB
191 {if $line.tax_rate != "" || $line.tax_amount != ""}
192 <td>
193 {$line.tax_rate|string_format:"%.2f"}%
194 </td>
195 <td>
196 {$line.tax_amount|crmMoney}
197 </td>
198 {else}
199 <td></td>
200 <td></td>
201 {/if}
79d001a2 202 {/if}
6a488035 203 <td>
7cf82823 204 {$line.line_total+$line.tax_amount|crmMoney}
6a488035 205 </td>
011aeb62 206 {if $pricesetFieldsCount }
207 <td>
208 {$line.participant_count}
6a488035 209 </td>
011aeb62 210 {/if}
6a488035
TO
211 </tr>
212 {/foreach}
213 </table>
214 </td>
215 </tr>
216 {/if}
217 {/foreach}
7cf82823 218 {if $dataArray}
79d001a2
PB
219 <tr>
220 <td {$labelStyle}>
d5be719d 221 {ts}Amount Before Tax:{/ts}
79d001a2
PB
222 </td>
223 <td {$valueStyle}>
224 {$totalAmount-$totalTaxAmount|crmMoney}
225 </td>
226 </tr>
227 {foreach from=$dataArray item=value key=priceset}
228 <tr>
7cf82823 229 {if $priceset || $priceset == 0}
7f7fa13a 230 <td>&nbsp;{$taxTerm} {$priceset|string_format:"%.2f"}%</td>
7cf82823
PB
231 <td>&nbsp;{$value|crmMoney:$currency}</td>
232 {else}
233 <td>&nbsp;{ts}No{/ts} {$taxTerm}</td>
234 <td>&nbsp;{$value|crmMoney:$currency}</td>
79d001a2
PB
235 {/if}
236 </tr>
237 {/foreach}
238 {/if}
6a488035
TO
239 {/if}
240
241 {if $amount && !$lineItem}
242 {foreach from=$amount item=amnt key=level}
243 <tr>
244 <td colspan="2" {$valueStyle}>
245 {$amnt.amount|crmMoney} {$amnt.label}
246 </td>
247 </tr>
248 {/foreach}
249 {/if}
79d001a2
PB
250 {if $totalTaxAmount}
251 <tr>
252 <td {$labelStyle}>
253 {ts}Total Tax Amount{/ts}
254 </td>
255 <td {$valueStyle}>
256 {$totalTaxAmount|crmMoney:$currency}
257 </td>
258 </tr>
259 {/if}
6a488035
TO
260 {if $isPrimary}
261 <tr>
262 <td {$labelStyle}>
81f3d017
PJ
263 {if $balanceAmount}
264 {ts}Total Paid{/ts}
265 {else}
266 {ts}Total Amount{/ts}
267 {/if}
6a488035
TO
268 </td>
269 <td {$valueStyle}>
270 {$totalAmount|crmMoney} {if $hookDiscount.message}({$hookDiscount.message}){/if}
271 </td>
272 </tr>
81f3d017
PJ
273 {if $balanceAmount}
274 <tr>
275 <td {$labelStyle}>
276 {ts}Balance{/ts}
277 </td>
278 <td {$valueStyle}>
279 {$balanceAmount|crmMoney}
280 </td>
281 </tr>
282 {/if}
6a488035
TO
283 {if $pricesetFieldsCount }
284 <tr>
011aeb62 285 <td {$labelStyle}>
286 {ts}Total Participants{/ts}</td>
6a488035 287 <td {$valueStyle}>
011aeb62 288 {assign var="count" value= 0}
6a488035
TO
289 {foreach from=$lineItem item=pcount}
290 {assign var="lineItemCount" value=0}
291 {if $pcount neq 'skip'}
292 {foreach from=$pcount item=p_count}
293 {assign var="lineItemCount" value=$lineItemCount+$p_count.participant_count}
294 {/foreach}
295 {if $lineItemCount < 1 }
296 assign var="lineItemCount" value=1}
011aeb62 297 {/if}
6a488035
TO
298 {assign var="count" value=$count+$lineItemCount}
299 {/if}
300 {/foreach}
011aeb62 301 {$count}
6a488035
TO
302 </td>
303 </tr>
304 {/if}
305 {if $is_pay_later}
306 <tr>
307 <td colspan="2" {$labelStyle}>
308 {$pay_later_receipt}
309 </td>
310 </tr>
311 {/if}
312
313 {if $register_date}
314 <tr>
315 <td {$labelStyle}>
316 {ts}Registration Date{/ts}
317 </td>
318 <td {$valueStyle}>
319 {$register_date|crmDate}
320 </td>
321 </tr>
322 {/if}
323
324 {if $receive_date}
325 <tr>
326 <td {$labelStyle}>
327 {ts}Transaction Date{/ts}
328 </td>
329 <td {$valueStyle}>
330 {$receive_date|crmDate}
331 </td>
332 </tr>
333 {/if}
334
b956b310 335 {if $financialTypeName}
6a488035
TO
336 <tr>
337 <td {$labelStyle}>
338 {ts}Financial Type{/ts}
339 </td>
340 <td {$valueStyle}>
b956b310 341 {$financialTypeName}
6a488035
TO
342 </td>
343 </tr>
344 {/if}
345
346 {if $trxn_id}
347 <tr>
348 <td {$labelStyle}>
349 {ts}Transaction #{/ts}
350 </td>
351 <td {$valueStyle}>
352 {$trxn_id}
353 </td>
354 </tr>
355 {/if}
356
357 {if $paidBy}
358 <tr>
359 <td {$labelStyle}>
360 {ts}Paid By{/ts}
361 </td>
362 <td {$valueStyle}>
363 {$paidBy}
364 </td>
365 </tr>
366 {/if}
367
368 {if $checkNumber}
369 <tr>
370 <td {$labelStyle}>
371 {ts}Check Number{/ts}
372 </td>
373 <td {$valueStyle}>
374 {$checkNumber}
375 </td>
376 </tr>
377 {/if}
378
379 {if $contributeMode ne 'notify' and !$isAmountzero and !$is_pay_later and !$isOnWaitlist and !$isRequireApproval}
380 <tr>
381 <th {$headerStyle}>
382 {ts}Billing Name and Address{/ts}
383 </th>
384 </tr>
385 <tr>
386 <td colspan="2" {$valueStyle}>
387 {$billingName}<br />
388 {$address|nl2br}
389 </td>
390 </tr>
391 {/if}
392
393 {if $contributeMode eq 'direct' and !$isAmountzero and !$is_pay_later and !$isOnWaitlist and !$isRequireApproval}
394 <tr>
395 <th {$headerStyle}>
396 {ts}Credit Card Information{/ts}
397 </th>
398 </tr>
399 <tr>
400 <td colspan="2" {$valueStyle}>
401 {$credit_card_type}<br />
402 {$credit_card_number}<br />
403 {ts}Expires{/ts}: {$credit_card_exp_date|truncate:7:''|crmDate}
404 </td>
405 </tr>
406 {/if}
407
408 {/if}
409
410 {/if} {* End of conditional section for Paid events *}
411
412 {if $customPre}
413 <tr>
414 <th {$headerStyle}>
415 {$customPre_grouptitle}
416 </th>
417 </tr>
418 {foreach from=$customPre item=value key=customName}
419 {if ( $trackingFields and ! in_array( $customName, $trackingFields ) ) or ! $trackingFields}
420 <tr>
421 <td {$labelStyle}>
422 {$customName}
423 </td>
424 <td {$valueStyle}>
425 {$value}
426 </td>
427 </tr>
428 {/if}
429 {/foreach}
430 {/if}
431
432 {if $customPost}
433 <tr>
434 <th {$headerStyle}>
435 {$customPost_grouptitle}
436 </th>
437 </tr>
438 {foreach from=$customPost item=value key=customName}
439 {if ( $trackingFields and ! in_array( $customName, $trackingFields ) ) or ! $trackingFields}
440 <tr>
441 <td {$labelStyle}>
442 {$customName}
443 </td>
444 <td {$valueStyle}>
445 {$value}
446 </td>
447 </tr>
448 {/if}
449 {/foreach}
450 {/if}
451
452 {if $customProfile}
453 {foreach from=$customProfile item=value key=customName}
454 <tr>
455 <th {$headerStyle}>
456 {ts 1=$customName+1}Participant Information - Participant %1{/ts}
457 </th>
458 </tr>
459 {foreach from=$value item=val key=field}
460 {if $field eq 'additionalCustomPre' or $field eq 'additionalCustomPost'}
461 <tr>
462 <td colspan="2" {$labelStyle}>
463 {if $field eq 'additionalCustomPre'}
464 {$additionalCustomPre_grouptitle}
465 {else}
466 {$additionalCustomPost_grouptitle}
467 {/if}
468 </td>
469 </tr>
470 {foreach from=$val item=v key=f}
471 <tr>
472 <td {$labelStyle}>
473 {$f}
474 </td>
475 <td {$valueStyle}>
476 {$v}
477 </td>
478 </tr>
479 {/foreach}
480 {/if}
481 {/foreach}
482 {/foreach}
483 {/if}
484
485 {if $customGroup}
486 {foreach from=$customGroup item=value key=customName}
487 <tr>
488 <th {$headerStyle}>
489 {$customName}
490 </th>
491 </tr>
492 {foreach from=$value item=v key=n}
493 <tr>
494 <td {$labelStyle}>
495 {$n}
496 </td>
497 <td {$valueStyle}>
498 {$v}
499 </td>
500 </tr>
501 {/foreach}
502 {/foreach}
503 {/if}
504
505 </table>
506 </td>
507 </tr>
508
509 </table>
510</center>
511
512</body>
513</html>