Merge pull request #13213 from eileenmcnaughton/export_array
[civicrm-core.git] / templates / CRM / Case / Audit / Report.tpl
1 {*
2 +--------------------------------------------------------------------+
3 | CiviCRM version 5 |
4 +--------------------------------------------------------------------+
5 | Copyright CiviCRM LLC (c) 2004-2019 |
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 <html xmlns="http://www.w3.org/1999/xhtml" lang="{$config->lcMessages|truncate:2:"":true}" xml:lang="{$config->lcMessages|truncate:2:"":true}">
27 <head>
28 <title>{$pageTitle}</title>
29 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
30 <base href="{crmURL p="" a=1}" /><!--[if IE]></base><![endif]-->
31 <style type="text/css" media="screen, print">@import url({$config->userFrameworkResourceURL}css/print.css);</style>
32 </head>
33
34 <body>
35 <div id="crm-container" class="crm-container">
36 <h1>{$pageTitle}</h1>
37 <div id="report-date">{$reportDate}</div>
38 <h2>{ts}Case Summary{/ts}</h2>
39 <table class="report-layout">
40 <tr>
41 <th class="reports-header">{ts}Client{/ts}</th>
42 <th class="reports-header">{ts}Case Type{/ts}</th>
43 <th class="reports-header">{ts}Status{/ts}</th>
44 <th class="reports-header">{ts}Start Date{/ts}</th>
45 <th class="reports-header">{ts}Case ID{/ts}</th>
46 </tr>
47 <tr>
48 <td class="crm-case-report-clientName">{$case.clientName}</td>
49 <td class="crm-case-report-caseType">{$case.caseType}</td>
50 <td class="crm-case-report-status">{$case.status}</td>
51 <td class="crm-case-report-start_date">{$case.start_date}</td>
52 <td class="crm-case-report-{$caseId}">{$caseId}</td>
53 </tr>
54 </table>
55 <h2>{ts}Case Roles{/ts}</h2>
56 <table class ="report-layout">
57 <tr>
58 <th class="reports-header">{ts}Case Role{/ts}</th>
59 <th class="reports-header">{ts}Name{/ts}</th>
60 <th class="reports-header">{ts}Phone{/ts}</th>
61 <th class="reports-header">{ts}Email{/ts}</th>
62 </tr>
63
64 {foreach from=$caseRelationships item=row key=relId}
65 <tr>
66 <td class="crm-case-report-caserelationships-relation">{$row.relation}</td>
67 <td class="crm-case-report-caserelationships-name">{$row.name}</td>
68 <td class="crm-case-report-caserelationships-phone">{$row.phone}</td>
69 <td class="crm-case-report-caserelationships-email">{$row.email}</td>
70 </tr>
71 {/foreach}
72 {foreach from=$caseRoles item=relName key=relTypeID}
73 {if $relTypeID neq 'client'}
74 <tr>
75 <td>{$relName}</td>
76 <td>{ts}(not assigned){/ts}</td>
77 <td></td>
78 <td></td>
79 </tr>
80 {else}
81 <tr>
82 <td class="crm-case-report-caseroles-role">{$relName.role}</td>
83 <td class="crm-case-report-caseroles-sort_name">{$relName.sort_name}</td>
84 <td class="crm-case-report-caseroles-phone">{$relName.phone}</td>
85 <td class="crm-case-report-caseroles-email">{$relName.email}</td>
86 </tr>
87 {/if}
88 {/foreach}
89 </table>
90 <br />
91
92 {if $otherRelationships}
93 <table class ="report-layout">
94 <tr>
95 <th class="reports-header">{ts}Client Relationship{/ts}</th>
96 <th class="reports-header">{ts}Name{/ts}</th>
97 <th class="reports-header">{ts}Phone{/ts}</th>
98 <th class="reports-header">{ts}Email{/ts}</th>
99 </tr>
100 {foreach from=$otherRelationships item=row key=relId}
101 <tr>
102 <td class="crm-case-report-otherrelationships-relation">{$row.relation}</td>
103 <td class="crm-case-report-otherrelationships-name">{$row.name}</td>
104 <td class="crm-case-report-otherrelationships-phone">{$row.phone}</td>
105 <td class="crm-case-report-otherrelationships-email">{$row.email}</td>
106 </tr>
107 {/foreach}
108 </table>
109 <br />
110 {/if}
111
112 {if $globalRelationships}
113 <table class ="report-layout">
114 <tr>
115 <th class="reports-header">{$globalGroupInfo.title}</th>
116 <th class="reports-header">{ts}Phone{/ts}</th>
117 <th class="reports-header">{ts}Email{/ts}</th>
118 </tr>
119 {foreach from=$globalRelationships item=row key=relId}
120 <tr>
121 <td class="crm-case-report-globalrelationships-sort_name">{$row.sort_name}</td>
122 <td class="crm-case-report-globalrelationships-phone">{$row.phone}</td>
123 <td class="crm-case-report-globalrelationships-email">{$row.email}</td>
124 </tr>
125 {/foreach}
126 </table>
127 {/if}
128
129 {if $caseCustomFields}
130 {foreach from=$caseCustomFields item=group}
131 <h2>{$group.title}</h2>
132 <table class ="report-layout">
133 {foreach from=$group.values item=row}
134 <tr>
135 <th class="label">{$row.label}</td>
136 <td class="crm-case-report-custom-field">{$row.value}</td>
137 </tr>
138 {/foreach}
139 </table>
140 {/foreach}
141 {/if}
142
143 <h2>{ts}Case Activities{/ts}</h2>
144 {foreach from=$activities item=activity key=key}
145 <table class ="report-layout">
146 {foreach from=$activity item=field name=fieldloop}
147 <tr class="crm-case-report-activity-{$field.label}">
148 <th scope="row" class="label">{$field.label|escape}</th>
149 {if $field.label eq 'Activity Type' or $field.label eq 'Status'}
150 <td class="bold">{$field.value|escape}</td>
151 {elseif $field.label eq 'Details' or $field.label eq 'Subject'}
152 <td>{$field.value}</td>
153 {else}
154 <td>{$field.value|escape}</td>
155 {/if}
156 </tr>
157 {/foreach}
158 </table>
159 <br />
160 {/foreach}
161 </div>
162 </body>
163 </html>
164
165
166
167
168