'title.delete_file' => 'Deleting File',
'title.download_file' => 'Downloading File',
'title.work' => 'Work',
+'title.active_work' => 'Active Work', // Active work items this group outsources to other groups.
+'title.inactive_work' => 'Inactive Work', // Inactive work items this group was outsourcing to other groups.
// Section for common strings inside combo boxes on forms. Strings shared between forms shall be placed here.
// Strings that are used in a single form must go to the specific form section.
<br>
<table cellspacing="0" cellpadding="4" width="100%" border="0">
<tr>
- <td align="center"> Anuko Time Tracker 1.19.0.4958 | Copyright © <a href="https://www.anuko.com/lp/tt_3.htm" target="_blank">Anuko</a> |
+ <td align="center"> Anuko Time Tracker 1.19.0.4959 | Copyright © <a href="https://www.anuko.com/lp/tt_3.htm" target="_blank">Anuko</a> |
<a href="https://www.anuko.com/lp/tt_4.htm" target="_blank">{$i18n.footer.credits}</a> |
<a href="https://www.anuko.com/lp/tt_5.htm" target="_blank">{$i18n.footer.license}</a> |
<a href="https://www.anuko.com/lp/tt_7.htm" target="_blank">{$i18n.footer.improve}</a>
{if $user->isPluginEnabled('cl') && ($user->can('view_own_clients') || $user->can('manage_clients'))}
· <a class="mainMenu" href="clients.php">{$i18n.menu.clients}</a>
{/if}
- {if $user->isPluginEnabled('wk') && ($user->can('do_work') || $user->can('bid_on_work') || $user->can('manage_work')) && $user->exists()}
+ {if $user->isPluginEnabled('wk') && ($user->can('update_work') || $user->can('bid_on_work') || $user->can('manage_work')) && $user->exists()}
· <a class="mainMenu" href="work.php">{$i18n.title.work}</a>
{/if}
{if $user->can('export_data')}
--- /dev/null
+<script>
+ function chLocation(newLocation) { document.location = newLocation; }
+</script>
+
+<table cellspacing="0" cellpadding="7" border="0" width="720">
+ <tr>
+ <td valign="top">
+{if $user->can('manage_work')}
+ <table cellspacing="1" cellpadding="3" border="0" width="100%">
+ <tr><td class="sectionHeaderNoBorder">{$i18n.title.active_work}</td></tr>
+ <tr>
+ <td width="35%" class="tableHeader">{$i18n.label.thing_name}</td>
+ <td width="35%" class="tableHeader">{$i18n.label.description}</td>
+ {if $show_files}
+ <td></td>
+ {/if}
+ <td></td>
+ <td></td>
+ </tr>
+ {if $active_work}
+ {foreach $active_work as $work_item}
+ <tr bgcolor="{cycle values="#f5f5f5,#ffffff"}">
+ <td>{$work_item.name|escape}</td>
+ {if $show_files}
+ {if $project.has_files}
+ <td><a href="project_files.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.files}" src="images/icon_files.png"></a></td>
+ {else}
+ <td><a href="project_files.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.files}" src="images/icon_file.png"></a></td>
+ {/if}
+ {/if}
+ <td><a href="project_edit.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.edit}" src="images/icon_edit.png"></a></td>
+ <td><a href="project_delete.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.delete}" src="images/icon_delete.png"></a></td>
+ </tr>
+ {/foreach}
+ {/if}
+ </table>
+
+ <table width="100%">
+ <tr>
+ <td align="center"><br>
+ <form><input type="button" onclick="chLocation('work_add.php');" value="{$i18n.button.add}"></form>
+ </td>
+ </tr>
+ </table>
+
+ {if $inactive_projects}
+ <table cellspacing="1" cellpadding="3" border="0" width="100%">
+ <tr><td class="sectionHeaderNoBorder">{$i18n.form.projects.inactive_projects}</td></tr>
+ <tr>
+ <td width="35%" class="tableHeader">{$i18n.label.thing_name}</td>
+ <td width="35%" class="tableHeader">{$i18n.label.description}</td>
+ {if $show_files}
+ <td></td>
+ {/if}
+ <td></td>
+ <td></td>
+ </tr>
+ {foreach $inactive_projects as $project}
+ <tr bgcolor="{cycle values="#f5f5f5,#ffffff"}">
+ <td>{$project.name|escape}</td>
+ <td>{$project.description|escape}</td>
+ {if $show_files}
+ {if $project.has_files}
+ <td><a href="project_files.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.files}" src="images/icon_files.png"></a></td>
+ {else}
+ <td><a href="project_files.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.files}" src="images/icon_file.png"></a></td>
+ {/if}
+ {/if}
+ <td><a href="project_edit.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.edit}" src="images/icon_edit.png"></a></td>
+ <td><a href="project_delete.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.delete}" src="images/icon_delete.png"></a></td>
+ </tr>
+ {/foreach}
+ </table>
+
+ <table width="100%">
+ <tr>
+ <td align="center"><br>
+ <form><input type="button" onclick="chLocation('work_add.php');" value="{$i18n.button.add}"></form>
+ </td>
+ </tr>
+ </table>
+ {/if}
+{else}
+ <table cellspacing="1" cellpadding="3" border="0" width="100%">
+ <tr>
+ <td class="tableHeader">{$i18n.label.thing_name}</td>
+ <td class="tableHeader">{$i18n.label.description}</td>
+ {if $show_files}
+ <td></td>
+ {/if}
+ </tr>
+ {if $active_projects}
+ {foreach $active_projects as $project}
+ <tr bgcolor="{cycle values="#f5f5f5,#ffffff"}">
+ <td>{$project.name|escape}</td>
+ <td>{$project.description|escape}</td>
+ {if $show_files && $project.has_files}
+ <td><a href="project_files.php?id={$project.id}"><img class="table_icon" alt="{$i18n.label.files}" src="images/icon_files.png"></a></td>
+ {/if}
+ </tr>
+ {/foreach}
+ {/if}
+ </table>
+{/if}
+ </td>
+ </tr>
+</table>
--- /dev/null
+<?php
+// +----------------------------------------------------------------------+
+// | Anuko Time Tracker
+// +----------------------------------------------------------------------+
+// | Copyright (c) Anuko International Ltd. (https://www.anuko.com)
+// +----------------------------------------------------------------------+
+// | LIBERAL FREEWARE LICENSE: This source code document may be used
+// | by anyone for any purpose, and freely redistributed alone or in
+// | combination with other software, provided that the license is obeyed.
+// |
+// | There are only two ways to violate the license:
+// |
+// | 1. To redistribute this code in source form, with the copyright
+// | notice or license removed or altered. (Distributing in compiled
+// | forms without embedded copyright notices is permitted).
+// |
+// | 2. To redistribute modified versions of this code in *any* form
+// | that bears insufficient indications that the modifications are
+// | not the work of the original author(s).
+// |
+// | This license applies to this document only, not any other software
+// | that it may be combined with.
+// |
+// +----------------------------------------------------------------------+
+// | Contributors:
+// | https://www.anuko.com/time_tracker/credits.htm
+// +----------------------------------------------------------------------+
+
+require_once('initialize.php');
+import('ttGroupHelper');
+
+// Access checks.
+if (!(ttAccessAllowed('update_work') || ttAccessAllowed('bid_on_work') || ttAccessAllowed('manage_work'))) {
+ header('Location: access_denied.php');
+ exit();
+}
+if (!$user->isPluginEnabled('wk')) {
+ header('Location: feature_disabled.php');
+ exit();
+}
+// End of access checks.
+
+if($user->can('manage_work')) {
+ // $active_work = ttWorkHelper::getActiveWork(); // Active work items this group is outsourcing.
+ // $inactive_work = ttWorkHelper::getInactiveWork(); // Inactive work items this group was outsourcing.
+}
+if($user->can('bid_on_work')) {
+ // $available_work = ttWorkHelper::getAvailableWork(); // Currently available work items from other groups.
+}
+if($user->can('update_work')) {
+ // $in_progress_work = ttWorkHelper::getInProgressWork(); // Work items in progress for other groups.
+ // $completed_work = ttWorkHelper::getCompletedWork(); // Completed work items for other groups.
+}
+
+$smarty->assign('active_work', $active_work);
+$smarty->assign('inactive_work', $inactive_work);
+$smarty->assign('available_work', $available_work);
+$smarty->assign('in_progress_work', $in_progress_work);
+$smarty->assign('completed_work', $completed_work);
+$smarty->assign('title', $i18n->get('title.work'));
+$smarty->assign('content_page_name', 'work.tpl');
+$smarty->display('index.tpl');