Merge pull request #21259 from demeritcowboy/better-file
[civicrm-core.git] / xml / templates / message_templates / membership_offline_receipt_html.tpl
CommitLineData
d4bb54f6 1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
2 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
6a488035
TO
3<html xmlns="http://www.w3.org/1999/xhtml">
4<head>
d4bb54f6 5 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
6 <title></title>
6a488035
TO
7</head>
8<body>
9
10{capture assign=headerStyle}colspan="2" style="text-align: left; padding: 4px; border-bottom: 1px solid #999; background-color: #eee;"{/capture}
11{capture assign=labelStyle }style="padding: 4px; border-bottom: 1px solid #999; background-color: #f7f7f7;"{/capture}
12{capture assign=valueStyle }style="padding: 4px; border-bottom: 1px solid #999;"{/capture}
13
14<center>
d4bb54f6 15 <table id="crm-event_receipt"
16 style="font-family: Arial, Verdana, sans-serif; text-align: left; width:100%; max-width:700px; padding:0; margin:0; border:0px;">
6a488035 17
d4bb54f6 18 <!-- BEGIN HEADER -->
19 <!-- You can add table row(s) here with logo or other header elements -->
20 <!-- END HEADER -->
6a488035 21
d4bb54f6 22 <!-- BEGIN CONTENT -->
6a488035 23
d4bb54f6 24 <tr>
25 <td>
26 {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}<p>{$greeting},</p>{/if}
ff708ff0 27 {if !empty($formValues.receipt_text_signup)}
d4bb54f6 28 <p>{$formValues.receipt_text_signup|htmlize}</p>
ff708ff0 29 {elseif !empty($formValues.receipt_text_renewal)}
d4bb54f6 30 <p>{$formValues.receipt_text_renewal|htmlize}</p>
31 {else}
32 <p>{ts}Thank you for this contribution.{/ts}</p>
33 {/if}
6a488035 34 </td>
d4bb54f6 35 </tr>
36 <tr>
37 <td>
38 <table style="border: 1px solid #999; margin: 1em 0em 1em; border-collapse: collapse; width:100%;">
ff708ff0 39 {if empty($lineItem)}
6a488035 40 <tr>
d4bb54f6 41 <th {$headerStyle}>
42 {ts}Membership Information{/ts}
43 </th>
6a488035 44 </tr>
d4bb54f6 45 <tr>
46 <td {$labelStyle}>
47 {ts}Membership Type{/ts}
6a488035 48 </td>
d4bb54f6 49 <td {$valueStyle}>
50 {$membership_name}
6a488035 51 </td>
d4bb54f6 52 </tr>
53 {/if}
ff708ff0
SL
54 {if empty($cancelled)}
55 {if empty($lineItem)}
d4bb54f6 56 <tr>
57 <td {$labelStyle}>
58 {ts}Membership Start Date{/ts}
7cf82823 59 </td>
d4bb54f6 60 <td {$valueStyle}>
61 {$mem_start_date}
7cf82823 62 </td>
d4bb54f6 63 </tr>
64 <tr>
65 <td {$labelStyle}>
66 {ts}Membership End Date{/ts}
67 </td>
68 <td {$valueStyle}>
69 {$mem_end_date}
70 </td>
71 </tr>
72 {/if}
73 {if $formValues.total_amount OR $formValues.total_amount eq 0 }
74 <tr>
75 <th {$headerStyle}>
76 {ts}Membership Fee{/ts}
77 </th>
78 </tr>
a221e1e0 79 {if !empty($formValues.contributionType_name)}
d4bb54f6 80 <tr>
81 <td {$labelStyle}>
82 {ts}Financial Type{/ts}
83 </td>
84 <td {$valueStyle}>
85 {$formValues.contributionType_name}
86 </td>
87 </tr>
79d001a2 88 {/if}
d4bb54f6 89
ff708ff0 90 {if !empty($lineItem)}
d4bb54f6 91 {foreach from=$lineItem item=value key=priceset}
92 <tr>
93 <td colspan="2" {$valueStyle}>
94 <table> {* FIXME: style this table so that it looks like the text version (justification, etc.) *}
95 <tr>
96 <th>{ts}Item{/ts}</th>
97 <th>{ts}Fee{/ts}</th>
ff708ff0 98 {if !empty($dataArray)}
d4bb54f6 99 <th>{ts}SubTotal{/ts}</th>
100 <th>{ts}Tax Rate{/ts}</th>
101 <th>{ts}Tax Amount{/ts}</th>
102 <th>{ts}Total{/ts}</th>
103 {/if}
104 <th>{ts}Membership Start Date{/ts}</th>
105 <th>{ts}Membership End Date{/ts}</th>
106 </tr>
107 {foreach from=$value item=line}
108 <tr>
109 <td>
110 {if $line.html_type eq 'Text'}{$line.label}{else}{$line.field_title} - {$line.label}{/if} {if $line.description}
111 <div>{$line.description|truncate:30:"..."}</div>{/if}
112 </td>
113 <td>
114 {$line.line_total|crmMoney}
115 </td>
ff708ff0 116 {if !empty($dataArray)}
d4bb54f6 117 <td>
118 {$line.unit_price*$line.qty|crmMoney}
119 </td>
b0800b2c 120 {if isset($line.tax_rate) and ($line.tax_rate != "" || $line.tax_amount != "")}
d4bb54f6 121 <td>
122 {$line.tax_rate|string_format:"%.2f"}%
123 </td>
124 <td>
125 {$line.tax_amount|crmMoney}
126 </td>
127 {else}
128 <td></td>
129 <td></td>
130 {/if}
131 <td>
132 {$line.line_total+$line.tax_amount|crmMoney}
133 </td>
134 {/if}
135 <td>
136 {$line.start_date}
137 </td>
138 <td>
139 {$line.end_date}
140 </td>
141 </tr>
142 {/foreach}
143 </table>
144 </td>
145 </tr>
146 {/foreach}
ff708ff0 147 {if !empty($dataArray)}
141c8460 148 {if isset($formValues.total_amount) and isset($totalTaxAmount)}
d4bb54f6 149 <tr>
150 <td {$labelStyle}>
151 {ts}Amount Before Tax:{/ts}
152 </td>
153 <td {$valueStyle}>
154 {$formValues.total_amount-$totalTaxAmount|crmMoney}
155 </td>
156 </tr>
141c8460 157 {/if}
d4bb54f6 158 {foreach from=$dataArray item=value key=priceset}
159 <tr>
160 {if $priceset}
b0800b2c 161 <td>&nbsp;{if isset($taxTerm)}{$taxTerm}{/if} {$priceset|string_format:"%.2f"}%</td>
d4bb54f6 162 <td>&nbsp;{$value|crmMoney:$currency}</td>
163 {elseif $priceset == 0}
b0800b2c 164 <td>&nbsp;{ts}No{/ts} {if isset($taxTerm)}{$taxTerm}{/if}</td>
d4bb54f6 165 <td>&nbsp;{$value|crmMoney:$currency}</td>
166 {/if}
167 </tr>
168 {/foreach}
169 {/if}
170 {/if}
171 {if isset($totalTaxAmount)}
172 <tr>
173 <td {$labelStyle}>
174 {ts}Total Tax Amount{/ts}
175 </td>
176 <td {$valueStyle}>
177 {$totalTaxAmount|crmMoney:$currency}
178 </td>
179 </tr>
180 {/if}
181 <tr>
182 <td {$labelStyle}>
183 {ts}Amount{/ts}
184 </td>
185 <td {$valueStyle}>
186 {$formValues.total_amount|crmMoney}
187 </td>
188 </tr>
ff708ff0 189 {if !empty($receive_date)}
d4bb54f6 190 <tr>
191 <td {$labelStyle}>
192 {ts}Date Received{/ts}
193 </td>
194 <td {$valueStyle}>
195 {$receive_date|truncate:10:''|crmDate}
196 </td>
197 </tr>
198 {/if}
ff708ff0 199 {if !empty($formValues.paidBy)}
d4bb54f6 200 <tr>
201 <td {$labelStyle}>
202 {ts}Paid By{/ts}
203 </td>
204 <td {$valueStyle}>
205 {$formValues.paidBy}
206 </td>
207 </tr>
ff708ff0 208 {if !empty($formValues.check_number)}
d4bb54f6 209 <tr>
210 <td {$labelStyle}>
211 {ts}Check Number{/ts}
212 </td>
213 <td {$valueStyle}>
214 {$formValues.check_number}
215 </td>
216 </tr>
217 {/if}
218 {/if}
219 {/if}
220 {/if}
221 </table>
222 </td>
223 </tr>
224
ff708ff0 225 {if !empty($isPrimary)}
d4bb54f6 226 <tr>
011aeb62 227 <td>
d4bb54f6 228 <table style="border: 1px solid #999; margin: 1em 0em 1em; border-collapse: collapse; width:100%;">
6a488035 229
ff708ff0 230 {if !empty($billingName)}
d4bb54f6 231 <tr>
232 <th {$headerStyle}>
233 {ts}Billing Name and Address{/ts}
234 </th>
235 </tr>
236 <tr>
237 <td {$labelStyle}>
238 {$billingName}<br/>
239 {$address}
240 </td>
241 </tr>
242 {/if}
6a488035 243
ff708ff0 244 {if !empty($credit_card_type)}
d4bb54f6 245 <tr>
246 <th {$headerStyle}>
247 {ts}Credit Card Information{/ts}
248 </th>
249 </tr>
250 <tr>
251 <td {$valueStyle}>
252 {$credit_card_type}<br/>
253 {$credit_card_number}
254 </td>
255 </tr>
256 <tr>
257 <td {$labelStyle}>
258 {ts}Expires{/ts}
259 </td>
260 <td {$valueStyle}>
261 {$credit_card_exp_date|truncate:7:''|crmDate}
262 </td>
263 </tr>
264 {/if}
6a488035 265
d4bb54f6 266 </table>
6a488035 267 </td>
d4bb54f6 268 </tr>
269 {/if}
6a488035 270
ff708ff0 271 {if !empty($customValues)}
6a488035 272 <tr>
d4bb54f6 273 <td>
274 <table style="border: 1px solid #999; margin: 1em 0em 1em; border-collapse: collapse; width:100%;">
275 <tr>
276 <th {$headerStyle}>
277 {ts}Membership Options{/ts}
278 </th>
279 </tr>
280 {foreach from=$customValues item=value key=customName}
281 <tr>
282 <td {$labelStyle}>
283 {$customName}
284 </td>
285 <td {$valueStyle}>
286 {$value}
287 </td>
288 </tr>
289 {/foreach}
290 </table>
6a488035 291 </td>
d4bb54f6 292 </tr>
293 {/if}
6a488035 294
d4bb54f6 295 </table>
6a488035
TO
296</center>
297
298</body>
299</html>