Merge pull request #15619 from seamuslee001/fix_force_case_form_date
[civicrm-core.git] / xml / templates / message_templates / contribution_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>
56658066 24 {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}<p>{$greeting},</p>{/if}
6a488035
TO
25 {if $formValues.receipt_text}
26 <p>{$formValues.receipt_text|htmlize}</p>
27 {else}
12ff7379 28 <p>{ts}Below you will find a receipt for this contribution.{/ts}</p>
6a488035 29 {/if}
6a488035
TO
30 </td>
31 </tr>
32 <tr>
33 <td>
34 <table style="border: 1px solid #999; margin: 1em 0em 1em; border-collapse: collapse; width:100%;">
35 <tr>
36 <th {$headerStyle}>
37 {ts}Contribution Information{/ts}
38 </th>
39 </tr>
40 <tr>
41 <td {$labelStyle}>
42 {ts}Financial Type{/ts}
43 </td>
44 <td {$valueStyle}>
45 {$formValues.contributionType_name}
46 </td>
47 </tr>
48
49 {if $lineItem and !$is_quick_config}
50 {foreach from=$lineItem item=value key=priceset}
51 <tr>
52 <td colspan="2" {$valueStyle}>
53 <table> {* FIXME: style this table so that it looks like the text version (justification, etc.) *}
54 <tr>
55 <th>{ts}Item{/ts}</th>
56 <th>{ts}Qty{/ts}</th>
57 <th>{ts}Each{/ts}</th>
7cf82823 58 {if $getTaxDetails}
79d001a2
PB
59 <th>{ts}Subtotal{/ts}</th>
60 <th>{ts}Tax Rate{/ts}</th>
61 <th>{ts}Tax Amount{/ts}</th>
62 {/if}
6a488035
TO
63 <th>{ts}Total{/ts}</th>
64 </tr>
65 {foreach from=$value item=line}
66 <tr>
67 <td>
68 {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}
69 </td>
70 <td>
71 {$line.qty}
72 </td>
73 <td>
74 {$line.unit_price|crmMoney:$currency}
75 </td>
7cf82823 76 {if $getTaxDetails}
79d001a2
PB
77 <td>
78 {$line.unit_price*$line.qty|crmMoney:$currency}
79 </td>
7cf82823
PB
80 {if $line.tax_rate != "" || $line.tax_amount != ""}
81 <td>
01604562 82 {$line.tax_rate|string_format:"%.2f"}%
7cf82823
PB
83 </td>
84 <td>
85 {$line.tax_amount|crmMoney:$currency}
86 </td>
87 {else}
88 <td></td>
89 <td></td>
90 {/if}
79d001a2 91 {/if}
6a488035 92 <td>
7cf82823 93 {$line.line_total+$line.tax_amount|crmMoney:$currency}
6a488035
TO
94 </td>
95 </tr>
96 {/foreach}
97 </table>
98 </td>
99 </tr>
100 {/foreach}
101 {/if}
7cf82823 102 {if $getTaxDetails && $dataArray}
79d001a2
PB
103 <tr>
104 <td {$labelStyle}>
105 {ts} Amount before Tax : {/ts}
106 </td>
107 <td {$valueStyle}>
108 {$formValues.total_amount-$totalTaxAmount|crmMoney:$currency}
109 </td>
110 </tr>
111
112 {foreach from=$dataArray item=value key=priceset}
113 <tr>
7cf82823 114 {if $priceset || $priceset == 0 || $value != ''}
ebf2b57b 115 <td>&nbsp;{$taxTerm} {$priceset|string_format:"%.2f"}%</td>
79d001a2 116 <td>&nbsp;{$value|crmMoney:$currency}</td>
7cf82823 117 {else}
03b412ae 118 <td>&nbsp;{ts}No{/ts} {$taxTerm}</td>
79d001a2
PB
119 <td>&nbsp;{$value|crmMoney:$currency}</td>
120 {/if}
121 </tr>
122 {/foreach}
123 {/if}
124
01604562 125 {if isset($totalTaxAmount) && $totalTaxAmount !== 'null'}
79d001a2
PB
126 <tr>
127 <td {$labelStyle}>
128 {ts}Total Tax Amount{/ts}
129 </td>
130 <td {$valueStyle}>
131 {$totalTaxAmount|crmMoney:$currency}
132 </td>
133 </tr>
134 {/if}
6a488035
TO
135
136 <tr>
137 <td {$labelStyle}>
138 {ts}Total Amount{/ts}
139 </td>
140 <td {$valueStyle}>
141 {$formValues.total_amount|crmMoney:$currency}
142 </td>
143 </tr>
144
145 {if $receive_date}
146 <tr>
147 <td {$labelStyle}>
7bc6b5bb 148 {ts}Date Received{/ts}
6a488035
TO
149 </td>
150 <td {$valueStyle}>
151 {$receive_date|truncate:10:''|crmDate}
152 </td>
153 </tr>
154 {/if}
155
156 {if $receipt_date}
157 <tr>
158 <td {$labelStyle}>
159 {ts}Receipt Date{/ts}
160 </td>
161 <td {$valueStyle}>
162 {$receipt_date|truncate:10:''|crmDate}
163 </td>
164 </tr>
165 {/if}
166
167 {if $formValues.paidBy and !$formValues.hidden_CreditCard}
168 <tr>
169 <td {$labelStyle}>
170 {ts}Paid By{/ts}
171 </td>
172 <td {$valueStyle}>
173 {$formValues.paidBy}
174 </td>
175 </tr>
176 {if $formValues.check_number}
177 <tr>
178 <td {$labelStyle}>
179 {ts}Check Number{/ts}
180 </td>
181 <td {$valueStyle}>
182 {$formValues.check_number}
183 </td>
184 </tr>
185 {/if}
186 {/if}
187
188 {if $formValues.trxn_id}
189 <tr>
190 <td {$labelStyle}>
191 {ts}Transaction ID{/ts}
192 </td>
193 <td {$valueStyle}>
194 {$formValues.trxn_id}
195 </td>
196 </tr>
197 {/if}
198
199 {if $ccContribution}
200 <tr>
201 <th {$headerStyle}>
202 {ts}Billing Name and Address{/ts}
203 </th>
204 </tr>
205 <tr>
206 <td colspan="2" {$valueStyle}>
207 {$billingName}<br />
208 {$address|nl2br}
209 </td>
210 </tr>
211 <tr>
212 <th {$headerStyle}>
213 {ts}Credit Card Information{/ts}
214 </th>
215 </tr>
216 <tr>
217 <td colspan="2" {$valueStyle}>
218 {$credit_card_type}<br />
219 {$credit_card_number}<br />
220 {ts}Expires{/ts}: {$credit_card_exp_date|truncate:7:''|crmDate}
221 </td>
222 </tr>
223 {/if}
224
1421174e 225 {if $softCreditTypes and $softCredits}
226 {foreach from=$softCreditTypes item=softCreditType key=n}
227 <tr>
228 <th {$headerStyle}>
229 {$softCreditType}
230 </th>
231 </tr>
232 {foreach from=$softCredits.$n item=value key=label}
233 <tr>
234 <td {$labelStyle}>
235 {$label}
236 </td>
237 <td {$valueStyle}>
238 {$value}
239 </td>
240 </tr>
241 {/foreach}
242 {/foreach}
243 {/if}
244
6a488035
TO
245 {if $customGroup}
246 {foreach from=$customGroup item=value key=customName}
247 <tr>
248 <th {$headerStyle}>
249 {$customName}
250 </th>
251 </tr>
252 {foreach from=$value item=v key=n}
253 <tr>
254 <td {$labelStyle}>
255 {$n}
256 </td>
257 <td {$valueStyle}>
258 {$v}
259 </td>
260 </tr>
261 {/foreach}
262 {/foreach}
263 {/if}
264
6a488035
TO
265 {if $formValues.product_name}
266 <tr>
267 <th {$headerStyle}>
268 {ts}Premium Information{/ts}
269 </th>
270 </tr>
271 <tr>
272 <td colspan="2" {$labelStyle}>
273 {$formValues.product_name}
274 </td>
275 </tr>
276 {if $formValues.product_option}
277 <tr>
278 <td {$labelStyle}>
279 {ts}Option{/ts}
280 </td>
281 <td {$valueStyle}>
282 {$formValues.product_option}
283 </td>
284 </tr>
285 {/if}
286 {if $formValues.product_sku}
287 <tr>
288 <td {$labelStyle}>
289 {ts}SKU{/ts}
290 </td>
291 <td {$valueStyle}>
292 {$formValues.product_sku}
293 </td>
294 </tr>
295 {/if}
296 {if $fulfilled_date}
297 <tr>
298 <td {$labelStyle}>
299 {ts}Sent{/ts}
300 </td>
301 <td {$valueStyle}>
302 {$fulfilled_date|truncate:10:''|crmDate}
303 </td>
304 </tr>
305 {/if}
306 {/if}
307
308 </table>
309 </td>
310 </tr>
311
312 </table>
313</center>
314
315</body>
316</html>