Merge remote-tracking branch 'upstream/4.4' into 4.4-master-2014-04-07-15-32-51
[civicrm-core.git] / templates / CRM / Contribute / Form / ContributionView.tpl
1 {*
2 +--------------------------------------------------------------------+
3 | CiviCRM version 4.5 |
4 +--------------------------------------------------------------------+
5 | Copyright CiviCRM LLC (c) 2004-2014 |
6 +--------------------------------------------------------------------+
7 | This file is a part of CiviCRM. |
8 | |
9 | CiviCRM is free software; you can copy, modify, and distribute it |
10 | under the terms of the GNU Affero General Public License |
11 | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. |
12 | |
13 | CiviCRM is distributed in the hope that it will be useful, but |
14 | WITHOUT ANY WARRANTY; without even the implied warranty of |
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
16 | See the GNU Affero General Public License for more details. |
17 | |
18 | You should have received a copy of the GNU Affero General Public |
19 | License and the CiviCRM Licensing Exception along |
20 | with this program; if not, contact CiviCRM LLC |
21 | at info[AT]civicrm[DOT]org. If you have questions about the |
22 | GNU Affero General Public License or the licensing of CiviCRM, |
23 | see the CiviCRM license FAQ at http://civicrm.org/licensing |
24 +--------------------------------------------------------------------+
25 *}
26 <div class="crm-block crm-content-block crm-contribution-view-form-block">
27 <h3>{ts}View Contribution{/ts}</h3>
28
29 <div class="action-link">
30 <div class="crm-submit-buttons">
31 {if call_user_func(array('CRM_Core_Permission','check'), 'edit contributions')}
32 {assign var='urlParams' value="reset=1&id=$id&cid=$contact_id&action=update&context=$context"}
33 {if ( $context eq 'fulltext' || $context eq 'search' ) && $searchKey}
34 {assign var='urlParams' value="reset=1&id=$id&cid=$contact_id&action=update&context=$context&key=$searchKey"}
35 {/if}
36 <a class="button" href="{crmURL p='civicrm/contact/view/contribution' q=$urlParams}" accesskey="e"><span>
37 <div class="icon edit-icon"></div>{ts}Edit{/ts}</span>
38 </a>
39 {/if}
40 {if call_user_func(array('CRM_Core_Permission','check'), 'delete in CiviContribute')}
41 {assign var='urlParams' value="reset=1&id=$id&cid=$contact_id&action=delete&context=$context"}
42 {if ( $context eq 'fulltext' || $context eq 'search' ) && $searchKey}
43 {assign var='urlParams' value="reset=1&id=$id&cid=$contact_id&action=delete&context=$context&key=$searchKey"}
44 {/if}
45 <a class="button" href="{crmURL p='civicrm/contact/view/contribution' q=$urlParams}"><span>
46 <div class="icon delete-icon"></div>{ts}Delete{/ts}</span>
47 </a>
48 {/if}
49 {include file="CRM/common/formButtons.tpl" location="top"}
50 </div>
51 </div>
52 <table class="crm-info-panel">
53 <tr>
54 <td class="label">{ts}From{/ts}</td>
55 <td class="bold">{$displayName}</td>
56 </tr>
57 <tr>
58 <td class="label">{ts}Financial Type{/ts}</td>
59 <td>{$financial_type}{if $is_test} {ts}(test){/ts} {/if}</td>
60 </tr>
61 {if $lineItem}
62 <tr>
63 <td class="label">{ts}Contribution Amount{/ts}</td>
64 <td>{include file="CRM/Price/Page/LineItem.tpl" context="Contribution"}
65 {if $contribution_recur_id}
66 <strong>{ts}Recurring Contribution{/ts}</strong>
67 <br/>
68 {ts}Installments{/ts}: {if $recur_installments}{$recur_installments}{else}{ts}(ongoing){/ts}{/if}, {ts}Interval{/ts}: {$recur_frequency_interval} {$recur_frequency_unit}(s)
69 {/if}
70 </td>
71 </tr>
72 {else}
73 <tr>
74 <td class="label">{ts}Total Amount{/ts}</td>
75 <td><strong>{$total_amount|crmMoney:$currency}</strong>&nbsp;
76 {if $contribution_recur_id}
77 <strong>{ts}Recurring Contribution{/ts}</strong>
78 <br/>
79 {ts}Installments{/ts}: {if $recur_installments}{$recur_installments}{else}{ts}(ongoing){/ts}{/if}, {ts}Interval{/ts}: {$recur_frequency_interval} {$recur_frequency_unit}(s)
80 {/if}
81 </td>
82 </tr>
83 {/if}
84 {if $non_deductible_amount}
85 <tr>
86 <td class="label">{ts}Non-deductible Amount{/ts}</td>
87 <td>{$non_deductible_amount|crmMoney:$currency}</td>
88 </tr>
89 {/if}
90 {if $fee_amount}
91 <tr>
92 <td class="label">{ts}Fee Amount{/ts}</td>
93 <td>{$fee_amount|crmMoney:$currency}</td>
94 </tr>
95 {/if}
96 {if $net_amount}
97 <tr>
98 <td class="label">{ts}Net Amount{/ts}</td>
99 <td>{$net_amount|crmMoney:$currency}</td>
100 </tr>
101 {/if}
102
103 <tr>
104 <td class="label">{ts}Received{/ts}</td>
105 <td>{if $receive_date}{$receive_date|crmDate}{else}({ts}not available{/ts}){/if}</td>
106 </tr>
107 {if $to_financial_account }
108 <tr>
109 <td class="label">{ts}Received Into{/ts}</td>
110 <td>{$to_financial_account}</td>
111 </tr>
112 {/if}
113 <tr>
114 <td class="label">{ts}Contribution Status{/ts}</td>
115 <td {if $contribution_status_id eq 3} class="font-red bold"{/if}>{$contribution_status}
116 {if $contribution_status_id eq 2} {if $is_pay_later}: {ts}Pay Later{/ts} {else} : {ts}Incomplete Transaction{/ts} {/if}{/if}</td>
117 </tr>
118
119 {if $cancel_date}
120 <tr>
121 <td class="label">{ts}Cancelled / Refunded Date{/ts}</td>
122 <td>{$cancel_date|crmDate}</td>
123 </tr>
124 {if $cancel_reason}
125 <tr>
126 <td class="label">{ts}Cancellation / Refund Reason{/ts}</td>
127 <td>{$cancel_reason}</td>
128 </tr>
129 {/if}
130 {/if}
131 <tr>
132 <td class="label">{ts}Paid By{/ts}</td>
133 <td>{$payment_instrument}</td>
134 </tr>
135
136 {if $payment_instrument eq 'Check'|ts}
137 <tr>
138 <td class="label">{ts}Check Number{/ts}</td>
139 <td>{$check_number}</td>
140 </tr>
141 {/if}
142 <tr>
143 <td class="label">{ts}Source{/ts}</td>
144 <td>{$source}</td>
145 </tr>
146
147 {if $campaign}
148 <tr>
149 <td class="label">{ts}Campaign{/ts}</td>
150 <td>{$campaign}</td>
151 </tr>
152 {/if}
153
154 {if $contribution_page_title}
155 <tr>
156 <td class="label">{ts}Online Contribution Page{/ts}</td>
157 <td>{$contribution_page_title}</td>
158 </tr>
159 {/if}
160 {if $receipt_date}
161 <tr>
162 <td class="label">{ts}Receipt Sent{/ts}</td>
163 <td>{$receipt_date|crmDate}</td>
164 </tr>
165 {/if}
166 {foreach from=$note item="rec"}
167 {if $rec }
168 <tr>
169 <td class="label">{ts}Note{/ts}</td>
170 <td>{$rec}</td>
171 </tr>
172 {/if}
173 {/foreach}
174
175 {if $trxn_id}
176 <tr>
177 <td class="label">{ts}Transaction ID{/ts}</td>
178 <td>{$trxn_id}</td>
179 </tr>
180 {/if}
181
182 {if $invoice_id}
183 <tr>
184 <td class="label">{ts}Invoice ID{/ts}</td>
185 <td>{$invoice_id}&nbsp;</td>
186 </tr>
187 {/if}
188
189 {if $thankyou_date}
190 <tr>
191 <td class="label">{ts}Thank-you Sent{/ts}</td>
192 <td>{$thankyou_date|crmDate}</td>
193 </tr>
194 {/if}
195 </table>
196
197 {if count($softContributions)} {* We show soft credit name with PCP section if contribution is linked to a PCP. *}
198 <div class="crm-accordion-wrapper crm-soft-credit-pane">
199 <div class="crm-accordion-header">
200 {ts}Soft Credit{/ts}
201 </div>
202 <div class="crm-accordion-body">
203 <table class="crm-info-panel crm-soft-credit-listing">
204 {foreach from=$softContributions item="softCont"}
205 <tr>
206 <td>
207 <a href="{crmURL p="civicrm/contact/view" q="reset=1&cid=`$softCont.contact_id`"}"
208 title="{ts}View contact record{/ts}">{$softCont.contact_name}
209 </a>
210 </td>
211 <td>{$softCont.amount|crmMoney:$currency}
212 {if $softCont.soft_credit_type_label}
213 ({$softCont.soft_credit_type_label})
214 {/if}
215 </td>
216 </tr>
217 {/foreach}
218 </table>
219 </div>
220 </div>
221 {/if}
222
223 {if $premium}
224 <div class="crm-accordion-wrapper ">
225 <div class="crm-accordion-header">
226 {ts}Premium Information{/ts}
227 </div>
228 <div class="crm-accordion-body">
229 <table class="crm-info-panel">
230 <td class="label">{ts}Premium{/ts}</td>
231 <td>{$premium}</td>
232 <td class="label">{ts}Option{/ts}</td>
233 <td>{$option}</td>
234 <td class="label">{ts}Fulfilled{/ts}</td>
235 <td>{$fulfilled|truncate:10:''|crmDate}</td>
236 </table>
237 </div>
238 </div>
239 {/if}
240
241 {if $pcp_id}
242 <div id='PCPView' class="crm-accordion-wrapper ">
243 <div class="crm-accordion-header">
244 {ts}Personal Campaign Page Contribution Information{/ts}
245 </div>
246 <div class="crm-accordion-body">
247 <table class="crm-info-panel">
248 <tr>
249 <td class="label">{ts}Personal Campaign Page{/ts}</td>
250 <td><a href="{crmURL p="civicrm/pcp/info" q="reset=1&id=`$pcp_id`"}">{$pcp_title}</a><br/>
251 <span class="description">{ts}Contribution was made through this personal campaign page.{/ts}</span>
252 </td>
253 </tr>
254 <tr>
255 <td class="label">{ts}Soft Credit To{/ts}</td>
256 <td><a href="{crmURL p="civicrm/contact/view" q="reset=1&cid=`$pcp_soft_credit_to_id`"}" id="view_contact"
257 title="{ts}View contact record{/ts}">{$pcp_soft_credit_to_name}</a></td>
258 </tr>
259 <tr>
260 <td class="label">{ts}In Public Honor Roll?{/ts}</td>
261 <td>{if $pcp_display_in_roll}{ts}Yes{/ts}{else}{ts}No{/ts}{/if}</td>
262 </tr>
263 {if $pcp_roll_nickname}
264 <tr>
265 <td class="label">{ts}Honor Roll Name{/ts}</td>
266 <td>{$pcp_roll_nickname}</td>
267 </tr>
268 {/if}
269 {if $pcp_personal_note}
270 <tr>
271 <td class="label">{ts}Personal Note{/ts}</td>
272 <td>{$pcp_personal_note}</td>
273 </tr>
274 {/if}
275 </table>
276 </div>
277 </div>
278 {/if}
279
280 {include file="CRM/Custom/Page/CustomDataView.tpl"}
281
282 {if $billing_address}
283 <fieldset>
284 <legend>{ts}Billing Address{/ts}</legend>
285 <div class="form-item">
286 {$billing_address|nl2br}
287 </div>
288 </fieldset>
289 {/if}
290
291 <div class="crm-submit-buttons">
292 {if call_user_func(array('CRM_Core_Permission','check'), 'edit contributions')}
293 {assign var='urlParams' value="reset=1&id=$id&cid=$contact_id&action=update&context=$context"}
294 {if ( $context eq 'fulltext' || $context eq 'search' ) && $searchKey}
295 {assign var='urlParams' value="reset=1&id=$id&cid=$contact_id&action=update&context=$context&key=$searchKey"}
296 {/if}
297 <a class="button" href="{crmURL p='civicrm/contact/view/contribution' q=$urlParams}" accesskey="e"><span><div
298 class="icon edit-icon"></div>{ts}Edit{/ts}</span></a>
299 {/if}
300 {if call_user_func(array('CRM_Core_Permission','check'), 'delete in CiviContribute')}
301 {assign var='urlParams' value="reset=1&id=$id&cid=$contact_id&action=delete&context=$context"}
302 {if ( $context eq 'fulltext' || $context eq 'search' ) && $searchKey}
303 {assign var='urlParams' value="reset=1&id=$id&cid=$contact_id&action=delete&context=$context&key=$searchKey"}
304 {/if}
305 <a class="button" href="{crmURL p='civicrm/contact/view/contribution' q=$urlParams}"><span><div
306 class="icon delete-icon"></div>{ts}Delete{/ts}</span></a>
307 {/if}
308 {include file="CRM/common/formButtons.tpl" location="bottom"}
309 </div>
310 </div>