Merge pull request #5594 from colemanw/CRM-16260
[civicrm-core.git] / templates / CRM / Admin / Page / LabelFormats.tpl
CommitLineData
6a488035
TO
1{*
2 +--------------------------------------------------------------------+
39de6fd5 3 | CiviCRM version 4.6 |
6a488035
TO
4 +--------------------------------------------------------------------+
5 | Copyright (C) 2011 Marty Wright |
6 | Licensed to CiviCRM under the Academic Free License version 3.0. |
7 +--------------------------------------------------------------------+
8 | This file is a part of CiviCRM. |
9 | |
10 | CiviCRM is free software; you can copy, modify, and distribute it |
11 | under the terms of the GNU Affero General Public License |
12 | Version 3, 19 November 2007 and the CiviCRM Licensing Exception. |
13 | |
14 | CiviCRM is distributed in the hope that it will be useful, but |
15 | WITHOUT ANY WARRANTY; without even the implied warranty of |
16 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
17 | See the GNU Affero General Public License for more details. |
18 | |
19 | You should have received a copy of the GNU Affero General Public |
20 | License and the CiviCRM Licensing Exception along |
21 | with this program; if not, contact CiviCRM LLC |
22 | at info[AT]civicrm[DOT]org. If you have questions about the |
23 | GNU Affero General Public License or the licensing of CiviCRM, |
24 | see the CiviCRM license FAQ at http://civicrm.org/licensing |
25 +--------------------------------------------------------------------+
26*}
27{* this template is for configuring label formats *}
28<div class="help">
252708df 29 {ts}You can configure one or more Label Formats for your CiviCRM installation. Label Formats are used when creating mailing labels.{/ts}
6a488035
TO
30</div>
31{if $action eq 1 or $action eq 2 or $action eq 8 or $action eq 16384}
252708df 32 {include file="CRM/Admin/Form/LabelFormats.tpl"}
6a488035
TO
33{else}
34
252708df
KJ
35 {if $rows}
36 <div id="ltype">
37 {strip}
e5e1786f 38 <table id="labelFormats" class="row-highlight">
252708df
KJ
39 <thead>
40 <tr class="columnheader">
e5e1786f
CW
41 <th>{ts}Name{/ts}</th>
42 <th>{ts}Used for{/ts}</th>
43 <th>{ts}Order{/ts}</th>
44 <th>{ts}Grouping{/ts}</th>
252708df
KJ
45 <th>{ts}Default?{/ts}</th>
46 <th>{ts}Reserved?{/ts}</th>
252708df
KJ
47 <th></th>
48 </tr>
49 </thead>
50 {foreach from=$rows item=row}
51 <tr id="row_{$row.id}" class="crm-labelFormat {cycle values="odd-row,even-row"} {$row.class}">
52 <td class="crm-labelFormat-name">{$row.label}</td>
53 <td class="crm-labelFormat-name">{$row.groupName}</td>
e5e1786f 54 <td class="crm-labelFormat-order nowrap">{$row.weight}</td>
252708df
KJ
55 <td class="crm-labelFormat-description">{$row.grouping}</td>
56 <td class="crm-labelFormat-is_default">{if $row.is_default eq 1}<img
57 src="{$config->resourceBase}i/check.gif" alt="{ts}Default{/ts}"/>{/if}&nbsp;</td>
58 <td class="crm-labelFormat-is_reserved">{if $row.is_reserved eq 1}{ts}Yes{/ts}{else}{ts}No{/ts}{/if}
59 &nbsp;</td>
252708df
KJ
60 <td>{$row.action|replace:'xx':$row.id}</td>
61 </tr>
62 {/foreach}
6a488035 63 </table>
252708df 64 {/strip}
6a488035
TO
65
66 <div class="action-link">
252708df 67 <a href="{crmURL q="action=add&reset=1"}" id="newLabelFormat" class="button"><span><div
52604b19 68 class="icon ui-icon-circle-plus"></div>{ts}Add Label Format{/ts}</span></a>
252708df
KJ
69 </div>
70 </div>
71 {else}
6a488035
TO
72 <div class="messages status no-popup">
73 <div class="icon inform-icon"></div>
252708df
KJ
74 {capture assign=crmURL}{crmURL p='civicrm/admin/labelFormats' q="action=add&reset=1"}{/capture}
75 {ts 1=$crmURL}There are no Label Formats configured. You can<a href='%1'>add one</a>.{/ts}
6a488035 76 </div>
252708df 77 {/if}
6a488035 78{/if}