A bit of refactoring.
[timetracker.git] / WEB-INF / templates / groups.tpl
1 <script>
2   function chLocation(newLocation) { document.location = newLocation; }
3 </script>
4 {$forms.subgroupsForm.open}
5 {if $group_dropdown}
6 <table cellspacing="1" cellpadding="3" border="0" width="100%">
7   <tr>
8     <td align="center">{$i18n.label.group}: {$forms.subgroupsForm.group.control}</td>
9   </tr>
10   <tr><td>&nbsp;</td></tr>
11 </table>
12 {/if}
13 {if $subgroups}
14 <table cellspacing="1" cellpadding="3" border="0" width="720">
15   <tr>
16     <td width="40%" class="tableHeader">{$i18n.label.thing_name}</td>
17     <td width="40%" class="tableHeader">{$i18n.label.description}</td>
18     <td></td>
19     <td></td>
20   </tr>
21   {foreach $subgroups as $subgroup}
22   <tr bgcolor="{cycle values="#f5f5f5,#ffffff"}">
23     <td>{$subgroup.name|escape}</td>
24     <td>{$subgroup.description|escape}</td>
25     <td><a href="group_edit.php?id={$subgroup.id}"><img class="table_icon" alt="{$i18n.label.edit}" src="images/icon_edit.png"></a></td>
26     <td><a href="group_delete.php?id={$subgroup.id}"><img class="table_icon" alt="{$i18n.label.delete}" src="images/icon_delete.png"></a></td>
27   </tr>
28   {/foreach}
29 </table>
30 {/if}
31 {$forms.subgroupsForm.close}
32
33 <table width="100%">
34   <tr>
35     <td align="center">
36       <br>
37       <form>
38         <input type="button" onclick="chLocation('group_add.php');" value="{$i18n.button.add}">
39       </form>
40     </td>
41   </tr>
42 </table>