A bit more work in progress on timesheet view.
[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       </table>
15     </td>
16   </tr>
17   <tr>
18     <td valign="top">
19 {if $invoice_items}
20       <table border="0" cellpadding="3" cellspacing="1" width="100%">
21         <tr>
22           <td class="tableHeader">{$i18n.label.date}</td>
23           <td class="tableHeader">{$i18n.form.invoice.person}</td>
24   {if $show_project}
25           <td class="tableHeader">{$i18n.label.project}</td>
26   {/if}
27   {if $show_task}
28           <td class="tableHeader">{$i18n.label.task}</td>
29   {/if}
30           <td class="tableHeader">{$i18n.label.note}</td>
31           <td class="tableHeaderCentered" width="5%">{$i18n.label.duration}</td>
32           <td class="tableHeaderCentered" width="5%">{$i18n.label.cost}</td>
33   {if $user->isPluginEnabled('ps')}
34           <td class="tableHeader">{$i18n.label.paid}</td>
35   {/if}
36         </tr>
37   {foreach $invoice_items as $invoice_item}
38         <tr bgcolor="{cycle values="#f5f5f5,#ffffff"}">
39           <td valign="top">{$invoice_item.date}</td>
40           <td valign="top">{$invoice_item.user_name|escape}</td>
41     {if $show_project}
42           <td valign="top">{$invoice_item.project_name|escape}</td>
43     {/if}
44     {if $show_task}
45           <td valign="top">{$invoice_item.task_name|escape}</td>
46     {/if}
47           <td valign="top">{$invoice_item.note|escape}</td>
48           <td align="right" valign="top">{$invoice_item.duration}</td>
49           <td align="right" valign="top">{$invoice_item.cost}</td>
50     {if $user->isPluginEnabled('ps')}
51           <td align="right" valign="top">{if $invoice_item.paid}{$i18n.label.yes}{else}{$i18n.label.no}{/if}</td>
52     {/if}
53         </tr>
54   {/foreach}
55         <tr><td>&nbsp;</td></tr>
56   {if $tax}
57         <tr>
58           <td align="right" colspan="{$colspan}"><b>{$i18n.label.subtotal}:</b></td>
59           <td align="right"><nobr>{$subtotal|escape}</nobr></td>
60         </tr>
61         <tr>
62           <td align="right" colspan="{$colspan}"><b>{$i18n.label.tax}:</b></td>
63           <td align="right"><nobr>{$tax|escape}</nobr></td>
64         </tr>
65    {/if}
66         <tr>
67           <td align="right" colspan="{$colspan}"><b>{$i18n.label.total}:</b></td>
68           <td align="right"><nobr>{$total|escape}</nobr></td>
69         </tr>
70       </table>
71
72   {$forms.invoiceForm.open}
73   {if $user->isPluginEnabled('ps')}
74   <table width="720" cellspacing="0" cellpadding="0" border="0">
75   <tr>
76     <td align="right">
77       <table>
78         <tr><td>{$i18n.label.mark_paid}: {$forms.invoiceForm.mark_paid_action_options.control} {$forms.invoiceForm.btn_mark_paid.control}</td></tr>
79       </table>
80     </td>
81   </tr>
82   </table>
83   {/if}
84   {$forms.invoiceForm.close}
85 {/if}
86     </td>
87   </tr>
88   <tr><td align="center"><br><form>
89     <input type="button" onclick="chLocation('invoice_send.php?id={$invoice_id}');" value="{$i18n.button.send_by_email}">
90   </form></td></tr>
91 </table>