Merge pull request #3113 from deepak-srivastava/CRM-14431
[civicrm-core.git] / templates / CRM / Admin / Page / CaseType.tpl
CommitLineData
8ffdec17
ARW
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{if $action eq 1 or $action eq 2 or $action eq 8}
27 {include file="CRM/Admin/Form/CaseType.tpl"}
28{else}
29 <div id="help">
30 {ts}A Case Type describes a group of related tasks, interactions, or processes.{/ts}
31 </div>
32
33{if $rows}
34<div id="casetype">
35 {strip}
36 {* handle enable/disable actions*}
37 {include file="CRM/common/enableDisableApi.tpl"}
38 {include file="CRM/common/crmeditable.tpl"}
39 {include file="CRM/common/jsortable.tpl"}
40 <table id="options" class="display">
41 <thead>
42 <tr>
43 <th id="sortable">{ts}Name{/ts}</th>
44 <th>{ts}Title{/ts}</th>
45 <th id="nosort">{ts}Description{/ts}</th>
46 <th>{ts}Enabled?{/ts}</th>
47 <th>{ts}Reserved?{/ts}</th>
48 <th></th>
49 </tr>
50 </thead>
51 {foreach from=$rows item=row}
52 <tr id="case_type-{$row.id}" class="{cycle values="odd-row,even-row"} {$row.class} crm-entity {if NOT $row.is_active} disabled{/if}">
53 <td class="crm-caseType-name">{$row.name}</td>
54 <td class="crm-caseType-title">{$row.title}</td>
55 <td class="crm-caseType-description">{$row.description}</td>
56 <td id="row_{$row.id}_status" class="crm-caseType-is_active">{if $row.is_active eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}</td>
57 <td class="crm-caseType-is_reserved" >{if $row.is_reserved eq 1}<img src="{$config->resourceBase}i/check.gif" alt="{ts}Reserved{/ts}" />{/if}&nbsp;</td>
58 <td>{$row.action|replace:'xx':$row.id}</td>
59 </tr>
60 {/foreach}
61 </table>
62 {/strip}
63
64 {if $action ne 1 and $action ne 2}
65 <div class="action-link">
66 <a href="{crmURL q="action=add&reset=1"}" id="newCaseType" class="button"><span>&raquo; {ts}New Case Type{/ts}</span></a>
67 </div>
68 {/if}
69</div>
70{else}
71 <div class="messages status no-popup">
72 <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
73 {capture assign=crmURL}{crmURL p='civicrm/admin/options/case_type' q="action=add&reset=1"}{/capture}
74 {ts 1=$crmURL}There are no Case Types yet. You can <a href='%1'>add one</a>.{/ts}
75 </div>
76{/if}
77{/if}