Update copyright date for 2020
[civicrm-core.git] / templates / CRM / Financial / Page / FinancialAccount.tpl
CommitLineData
6a488035
TO
1{*
2 +--------------------------------------------------------------------+
fee14197 3 | CiviCRM version 5 |
6a488035 4 +--------------------------------------------------------------------+
f299f7db 5 | Copyright CiviCRM LLC (c) 2004-2020 |
6a488035
TO
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{if $action eq 1 or $action eq 2 or $action eq 8}
27 {include file="CRM/Financial/Form/FinancialAccount.tpl"}
28{else}
f6eedce7 29 <div class="help">
5aa9fb54 30 {capture assign="typeLink"}{crmURL p="civicrm/admin/financial/financialType" q="reset=1"}{/capture}
5c3522e8 31 {capture assign="paymentLink"}{crmURL p="civicrm/admin/options/payment_instrument" q="reset=1"}{/capture}
5aa9fb54 32 {capture assign="premiumLink"}{crmURL p="civicrm/admin/contribute/managePremiums" q="reset=1"}{/capture}
536f0e02 33 <p>{ts 1=$typeLink 2=$paymentLink 3=$premiumLink}Financial accounts correspond to those in your accounting system. <a href="%1">Financial types</a>, <a href="%2">payment methods</a>, and <a href="%3">premiums</a> are associated with financial accounts so that they can result in the proper double-entry transactions to export to your accounting system.{/ts}</p>
6a488035 34 </div>
036aa39d
MR
35
36<div class="crm-content-block crm-block">
6a488035
TO
37 {if $action ne 1 and $action ne 2}
38 <div class="action-link">
a2c70872 39 <a href="{crmURL q="action=add&reset=1"}" id="newFinancialAccount-top" class="button"><span><i class="crm-i fa-plus-circle"></i> {ts}Add Financial Account{/ts}</span></a>
6a488035
TO
40 </div>
41 {/if}
42
43 {if $rows}
44 {include file="CRM/common/jsortable.tpl"}
45 <div id="ltype">
46 <p></p>
47 <div class="form-item">
48 {strip}
1393e47e 49 {* handle enable/disable actions*}
4d17a233 50 {include file="CRM/common/enableDisableApi.tpl"}
6a488035 51 <table id="crm-financial_accounts" class="display">
036aa39d 52 <thead class="sticky">
6a488035
TO
53 <th>{ts}Name{/ts}</th>
54 <th>{ts}Description{/ts}</th>
55 <th>{ts}Acctg Code{/ts}</th>
56 <th id="sortable">{ts}Account Type{/ts}</th>
57 <th>{ts}Deductible?{/ts}</th>
58 <th>{ts}Reserved?{/ts}</th>
59 <th>{ts}Default?{/ts}</th>
60 <th>{ts}Enabled?{/ts}</th>
61 <th></th>
62 </thead>
63 {foreach from=$rows item=row}
134bc82c 64 <tr id="financial_account-{$row.id}" class="crm-entity {cycle values="odd-row,even-row"} {$row.class}{if NOT $row.is_active} disabled{/if}">
036aa39d
MR
65 <td class="crm-editable" data-field="name">{$row.name}</td>
66 <td class="crm-editable" data-field="description" data-type="textarea">{$row.description}</td>
67 <td class="crm-editable" data-field="accounting_code">{$row.accounting_code}</td>
68 <td>{$row.financial_account_type_id}{if $row.account_type_code} ({$row.account_type_code}){/if}</td>
69 <td>{if $row.is_deductible eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}</td>
70 <td>{if $row.is_reserved eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}</td>
71 <td>{if $row.is_default eq 1}<img src="{$config->resourceBase}i/check.gif" alt="{ts}Default{/ts}" /> {/if}</td>
72 <td id="row_{$row.id}_status">{if $row.is_active eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}</td>
73 <td>{$row.action|replace:'xx':$row.id}</td>
6a488035
TO
74 </tr>
75 {/foreach}
76 </table>
77 {/strip}
78
79 {if $action ne 1 and $action ne 2}
80 <div class="action-link">
a2c70872 81 <a href="{crmURL q="action=add&reset=1"}" id="newFinancialAccount-bottom" class="button"><span><i class="crm-i fa-plus-circle"></i> {ts}Add Financial Account{/ts}</span></a>
6a488035
TO
82 </div>
83 {/if}
84 </div>
85 </div>
86 {else}
87 <div class="messages status">
88 <div class="icon inform-icon"></div>
89 {capture assign=crmURL}{crmURL q="action=add&reset=1"}{/capture}
90 {ts 1=$crmURL}There are no Financial Account entered. You can <a href='%1'>add one</a>.{/ts}
1393e47e 91 </div>
6a488035 92 {/if}
036aa39d
MR
93</div>
94
5aa9fb54 95{/if}