e69882530cccd9109b819dffc889759c4c380038
[timetracker.git] / WEB-INF / templates / timesheet_view.tpl
1 <script>
2   function chLocation(newLocation) { document.location = newLocation; }
3 </script>
4
5 <table cellspacing="0" cellpadding="7" border="0" width="720">
6   <tr>
7     <td>
8       <table border=0 width=100%>
9         <tr><td align="center"><b style="font-size: 15pt; font-family: Arial, Helvetica, sans-serif;">{$timesheet['name']|escape} </b></td></tr>
10         <tr><td align="left"><b>{$i18n.label.user}:</b> {$timesheet['user_name']|escape}</td></tr>
11 {if $timesheet['client_id']}
12         <tr><td align="left"><b>{$i18n.label.client}:</b> {$timesheet['client_name']|escape}</td></tr>
13 {/if}
14         <tr><td align="left"><b>{$i18n.label.submitted}:</b> {if $timesheet.submit_status}{$i18n.label.yes}{else}{$i18n.label.no}{/if}</td></tr>
15 {if $timesheet['submitter_comment']}
16         <tr><td align="left"><b>{$i18n.label.comment}:</b> {$timesheet['submitter_comment']|escape}</td></tr>
17 {/if}
18 {if $timesheet['submit_status']}
19         <tr><td align="left"><b>{$i18n.label.approved}:</b> {if $timesheet.approval_status != null}{if $timesheet.approval_status}{$i18n.label.yes}{else}{$i18n.label.no}{/if}</td></tr>{/if}
20 {/if}
21 {if $timesheet['manager_comment']}
22         <tr><td align="left"><b>{$i18n.label.note}:</b> {$timesheet['manager_comment']|escape}</td></tr>
23 {/if}
24       </table>
25     </td>
26   </tr>
27   <tr>
28     <td valign="top">
29       <table border="0" cellpadding="3" cellspacing="1" width="100%">
30       <tr>
31         <td class="tableHeader">{$group_by_header|escape}</td>
32         <td class="tableHeaderCentered" width="5%">{$i18n.label.duration}</td>
33         <td class="tableHeaderCentered" width="5%">{$i18n.label.cost}</td>
34       </tr>
35   {foreach $subtotals as $subtotal}
36       <tr class="rowReportSubtotal">
37         <td class="cellLeftAlignedSubtotal">{if $subtotal['name']}{$subtotal['name']|escape}{else}&nbsp;{/if}</td>
38         <td class="cellRightAlignedSubtotal">{$subtotal['time']}</td>
39         <td class="cellRightAlignedSubtotal">{if $user->can('manage_invoices') || $user->isClient()}{$subtotal['cost']}{else}{$subtotal['expenses']}{/if}</td>
40       </tr>
41   {/foreach}
42       <tr><td>&nbsp;</td></tr>
43       <tr class="rowReportSubtotal">
44         <td class="cellLeftAlignedSubtotal">{$i18n.label.total}</td>
45         <td nowrap class="cellRightAlignedSubtotal">{$totals['time']}</td>
46         <td nowrap class="cellRightAlignedSubtotal">{$user->currency|escape} {if $user->can('manage_invoices') || $user->isClient()}{$totals['cost']}{else}{$totals['expenses']}{/if}</td>
47       </tr>
48       </table>
49
50 {$forms.timesheetForm.open}
51   {if $show_submit}
52   <table width="720" cellspacing="0" cellpadding="0" border="0">
53   <tr>
54     <td align="center">
55       <table>
56         <tr><td>{$i18n.form.mail.to}: {$forms.timesheetForm.approver.control} {$forms.timesheetForm.btn_submit.control}</td></tr>
57       </table>
58     </td>
59   </tr>
60   </table>
61   {/if}
62   {if $show_approve}
63   <table width="720" cellspacing="0" cellpadding="0" border="0">
64   <tr>
65     <td align="center">
66       <table>
67         <tr><td align="center">{$i18n.label.comment}:</td></tr>
68         <tr><td align="center">{$forms.timesheetForm.comment.control}</td></tr>
69         <tr><td align="center">{$forms.timesheetForm.btn_approve.control} {$forms.timesheetForm.btn_disapprove.control}</td></tr>
70       </table>
71     </td>
72   </tr>
73   </table>
74   {/if}
75 {$forms.timesheetForm.close}
76
77     </td>
78   </tr>
79 </table>