A bit more progress on removing dependency on canManageTeam().
[timetracker.git] / WEB-INF / templates / time_edit.tpl
1 {include file="time_script.tpl"}
2
3 {$forms.timeRecordForm.open}
4 <table cellspacing="4" cellpadding="7" border="0">
5 <tr>
6   <td>
7   <table width = "100%">
8   <tr>
9     <td valign="top">
10     <table border="0">
11 {if $user->isPluginEnabled('cl')}
12     <tr>
13       <td align="right">{$i18n.label.client}{if $user->isPluginEnabled('cm')} (*){/if}:</td>
14       <td>{$forms.timeRecordForm.client.control}</td>
15     </tr>
16 {/if}
17 {if $user->isPluginEnabled('iv')}
18     <tr>
19       <td align="right">&nbsp;</td>
20       <td><label>{$forms.timeRecordForm.billable.control}{$i18n.form.time.billable}</label></td>
21     </tr>
22 {/if}
23 {if ($user->can('manage_invoices') && $user->isPluginEnabled('ps'))}
24     <tr>
25       <td align="right">&nbsp;</td>
26       <td><label>{$forms.timeRecordForm.paid.control}{$i18n.label.paid}</label></td>
27     </tr>
28 {/if}
29 {if ($custom_fields && $custom_fields->fields[0])} 
30     <tr>
31       <td align="right">{$custom_fields->fields[0]['label']|escape}{if $custom_fields->fields[0]['required']} (*){/if}:</td><td>{$forms.timeRecordForm.cf_1.control}</td>
32     </tr>
33 {/if}
34 {if ($smarty.const.MODE_PROJECTS == $user->tracking_mode || $smarty.const.MODE_PROJECTS_AND_TASKS == $user->tracking_mode)}
35     <tr>
36       <td align="right">{$i18n.label.project} (*):</td>
37       <td>{$forms.timeRecordForm.project.control}</td>
38     </tr>
39 {/if}
40 {if ($smarty.const.MODE_PROJECTS_AND_TASKS == $user->tracking_mode)}
41     <tr>
42       <td align="right">{$i18n.label.task}{if $user->task_required} (*){/if}:</td>
43       <td>{$forms.timeRecordForm.task.control}</td>
44     </tr>
45 {/if}
46 {if (($smarty.const.TYPE_START_FINISH == $user->record_type) || ($smarty.const.TYPE_ALL == $user->record_type))}
47     <tr>
48       <td align="right">{$i18n.label.start}:</td>
49       <td>{$forms.timeRecordForm.start.control}&nbsp;<input onclick="setNow('start');" type="button" tabindex="-1" value="{$i18n.button.now}"></td>
50     </tr>
51     <tr>
52       <td align="right">{$i18n.label.finish}:</td>
53       <td>{$forms.timeRecordForm.finish.control}&nbsp;<input onclick="setNow('finish');" type="button" tabindex="-1" value="{$i18n.button.now}"></td>
54     </tr>
55 {/if}
56 {if (($smarty.const.TYPE_DURATION == $user->record_type) || ($smarty.const.TYPE_ALL == $user->record_type))}
57     <tr>
58       <td align="right">{$i18n.label.duration}:</td>
59       <td>{$forms.timeRecordForm.duration.control}&nbsp;{if $user->decimal_mark == ','}{str_replace('.', ',', $i18n.form.time.duration_format)}{else}{$i18n.form.time.duration_format}{/if}</td>
60     </tr>
61 {/if}
62     <tr>
63       <td align="right">{$i18n.label.date}:</td>
64       <td>{$forms.timeRecordForm.date.control}</td>
65     </tr>
66     <tr>
67       <td align="right">{$i18n.label.note}:</td>
68       <td>{$forms.timeRecordForm.note.control}</td>
69     </tr>
70     <tr>
71       <td colspan="2">&nbsp;</td>
72     </tr>
73     <tr>
74       <td></td>
75       <td align="left">{$forms.timeRecordForm.btn_save.control} {$forms.timeRecordForm.btn_copy.control} {$forms.timeRecordForm.btn_delete.control}</td>
76     </tr>
77     </table>
78     </td>
79     </tr>
80   </table>
81   </td>
82   </tr>
83 </table>
84 {$forms.timeRecordForm.close}