Merge pull request #12647 from compucorp/fix-case-type-issues
[civicrm-core.git] / xml / templates / message_templates / contribution_online_receipt_text.tpl
1 {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if}
2 {if $receipt_text}
3 {$receipt_text}
4 {/if}
5 {if $is_pay_later}
6
7 ===========================================================
8 {$pay_later_receipt}
9 ===========================================================
10 {else}
11
12 {ts}Please print this receipt for your records.{/ts}
13 {/if}
14
15 {if $amount}
16 ===========================================================
17 {ts}Contribution Information{/ts}
18
19 ===========================================================
20 {if $lineItem and $priceSetID and !$is_quick_config}
21 {foreach from=$lineItem item=value key=priceset}
22 ---------------------------------------------------------
23 {capture assign=ts_item}{ts}Item{/ts}{/capture}
24 {capture assign=ts_qty}{ts}Qty{/ts}{/capture}
25 {capture assign=ts_each}{ts}Each{/ts}{/capture}
26 {if $dataArray}
27 {capture assign=ts_subtotal}{ts}Subtotal{/ts}{/capture}
28 {capture assign=ts_taxRate}{ts}Tax Rate{/ts}{/capture}
29 {capture assign=ts_taxAmount}{ts}Tax Amount{/ts}{/capture}
30 {/if}
31 {capture assign=ts_total}{ts}Total{/ts}{/capture}
32 {$ts_item|string_format:"%-30s"} {$ts_qty|string_format:"%5s"} {$ts_each|string_format:"%10s"} {if $dataArray} {$ts_subtotal|string_format:"%10s"} {$ts_taxRate} {$ts_taxAmount|string_format:"%10s"} {/if} {$ts_total|string_format:"%10s"}
33 ----------------------------------------------------------
34 {foreach from=$value item=line}
35 {capture assign=ts_item}{if $line.html_type eq 'Text'}{$line.label}{else}{$line.field_title} - {$line.label}{/if} {if $line.description} {$line.description}{/if}{/capture}{$ts_item|truncate:30:"..."|string_format:"%-30s"} {$line.qty|string_format:"%5s"} {$line.unit_price|crmMoney:$currency|string_format:"%10s"} {if $dataArray}{$line.unit_price*$line.qty|crmMoney:$currency|string_format:"%10s"} {if $line.tax_rate != "" || $line.tax_amount != ""} {$line.tax_rate|string_format:"%.2f"} % {$line.tax_amount|crmMoney:$currency|string_format:"%10s"} {else} {/if} {/if} {$line.line_total+$line.tax_amount|crmMoney:$currency|string_format:"%10s"}
36 {/foreach}
37 {/foreach}
38
39 {if $dataArray}
40 {ts}Amount before Tax{/ts}: {$amount-$totalTaxAmount|crmMoney:$currency}
41
42 {foreach from=$dataArray item=value key=priceset}
43 {if $priceset || $priceset == 0}
44 {$taxTerm} {$priceset|string_format:"%.2f"}%: {$value|crmMoney:$currency}
45 {else}
46 {ts}No{/ts} {$taxTerm}: {$value|crmMoney:$currency}
47 {/if}
48 {/foreach}
49 {/if}
50
51 {if $totalTaxAmount}
52 {ts}Total Tax Amount{/ts}: {$totalTaxAmount|crmMoney:$currency}
53 {/if}
54
55 {ts}Total Amount{/ts}: {$amount|crmMoney:$currency}
56 {else}
57 {ts}Amount{/ts}: {$amount|crmMoney:$currency} {if $amount_level } - {$amount_level} {/if}
58 {/if}
59 {/if}
60 {if $receive_date}
61
62 {ts}Date{/ts}: {$receive_date|crmDate}
63 {/if}
64 {if $is_monetary and $trxn_id}
65 {ts}Transaction #{/ts}: {$trxn_id}
66 {/if}
67
68 {if $is_recur}
69 {ts}This is a recurring contribution.{/ts}
70
71 {if $cancelSubscriptionUrl}
72 {ts}You can cancel future contributions at:{/ts}
73
74 {$cancelSubscriptionUrl}
75
76 {/if}
77
78 {if $updateSubscriptionBillingUrl}
79 {ts}You can update billing details for this recurring contribution at:{/ts}
80
81 {$updateSubscriptionBillingUrl}
82
83 {/if}
84
85 {if $updateSubscriptionUrl}
86 {ts}You can update recurring contribution amount or change the number of installments for this recurring contribution at:{/ts}
87
88 {$updateSubscriptionUrl}
89
90 {/if}
91 {/if}
92
93 {if $honor_block_is_active}
94 ===========================================================
95 {$soft_credit_type}
96 ===========================================================
97 {foreach from=$honoreeProfile item=value key=label}
98 {$label}: {$value}
99 {/foreach}
100 {elseif $softCreditTypes and $softCredits}
101 {foreach from=$softCreditTypes item=softCreditType key=n}
102 ===========================================================
103 {$softCreditType}
104 ===========================================================
105 {foreach from=$softCredits.$n item=value key=label}
106 {$label}: {$value}
107 {/foreach}
108 {/foreach}
109 {/if}
110 {if $pcpBlock}
111 ===========================================================
112 {ts}Personal Campaign Page{/ts}
113
114 ===========================================================
115 {ts}Display In Honor Roll{/ts}: {if $pcp_display_in_roll}{ts}Yes{/ts}{else}{ts}No{/ts}{/if}
116
117 {if $pcp_roll_nickname}{ts}Nickname{/ts}: {$pcp_roll_nickname}{/if}
118
119 {if $pcp_personal_note}{ts}Personal Note{/ts}: {$pcp_personal_note}{/if}
120
121 {/if}
122 {if $onBehalfProfile}
123 ===========================================================
124 {ts}On Behalf Of{/ts}
125
126 ===========================================================
127 {foreach from=$onBehalfProfile item=onBehalfValue key=onBehalfName}
128 {$onBehalfName}: {$onBehalfValue}
129 {/foreach}
130 {/if}
131
132 {if !( $contributeMode eq 'notify' OR $contributeMode eq 'directIPN' ) and $is_monetary}
133 {if $is_pay_later && !$isBillingAddressRequiredForPayLater}
134 ===========================================================
135 {ts}Registered Email{/ts}
136
137 ===========================================================
138 {$email}
139 {elseif $amount GT 0}
140 ===========================================================
141 {ts}Billing Name and Address{/ts}
142
143 ===========================================================
144 {$billingName}
145 {$address}
146
147 {$email}
148 {/if} {* End ! is_pay_later condition. *}
149 {/if}
150 {if $contributeMode eq 'direct' AND !$is_pay_later AND $amount GT 0}
151
152 ===========================================================
153 {ts}Credit Card Information{/ts}
154
155 ===========================================================
156 {$credit_card_type}
157 {$credit_card_number}
158 {ts}Expires{/ts}: {$credit_card_exp_date|truncate:7:''|crmDate}
159 {/if}
160
161 {if $selectPremium }
162 ===========================================================
163 {ts}Premium Information{/ts}
164
165 ===========================================================
166 {$product_name}
167 {if $option}
168 {ts}Option{/ts}: {$option}
169 {/if}
170 {if $sku}
171 {ts}SKU{/ts}: {$sku}
172 {/if}
173 {if $start_date}
174 {ts}Start Date{/ts}: {$start_date|crmDate}
175 {/if}
176 {if $end_date}
177 {ts}End Date{/ts}: {$end_date|crmDate}
178 {/if}
179 {if $contact_email OR $contact_phone}
180
181 {ts}For information about this premium, contact:{/ts}
182
183 {if $contact_email}
184 {$contact_email}
185 {/if}
186 {if $contact_phone}
187 {$contact_phone}
188 {/if}
189 {/if}
190 {if $is_deductible AND $price}
191
192 {ts 1=$price|crmMoney:$currency}The value of this premium is %1. This may affect the amount of the tax deduction you can claim. Consult your tax advisor for more information.{/ts}{/if}
193 {/if}
194
195 {if $customPre}
196 ===========================================================
197 {$customPre_grouptitle}
198
199 ===========================================================
200 {foreach from=$customPre item=customValue key=customName}
201 {if ( $trackingFields and ! in_array( $customName, $trackingFields ) ) or ! $trackingFields}
202 {$customName}: {$customValue}
203 {/if}
204 {/foreach}
205 {/if}
206
207
208 {if $customPost}
209 ===========================================================
210 {$customPost_grouptitle}
211
212 ===========================================================
213 {foreach from=$customPost item=customValue key=customName}
214 {if ( $trackingFields and ! in_array( $customName, $trackingFields ) ) or ! $trackingFields}
215 {$customName}: {$customValue}
216 {/if}
217 {/foreach}
218 {/if}