Some more refactoring.
authorNik Okuntseff <support@anuko.com>
Sat, 14 Apr 2018 13:07:37 +0000 (13:07 +0000)
committerNik Okuntseff <support@anuko.com>
Sat, 14 Apr 2018 13:07:37 +0000 (13:07 +0000)
WEB-INF/templates/footer.tpl
WEB-INF/templates/reports.tpl

index 3ff2dda..16befd9 100644 (file)
@@ -12,7 +12,7 @@
       <br>
       <table cellspacing="0" cellpadding="4" width="100%" border="0">
         <tr>
-          <td align="center">&nbsp;Anuko Time Tracker 1.17.88.4266 | Copyright &copy; <a href="https://www.anuko.com/lp/tt_3.htm" target="_blank">Anuko</a> |
+          <td align="center">&nbsp;Anuko Time Tracker 1.17.88.4267 | Copyright &copy; <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>
index 8aa7f6d..a70a3f0 100644 (file)
@@ -221,7 +221,7 @@ function handleCheckboxes() {
           <td>{$forms.reportForm.paid_status.control}</td>
         </tr>
 {/if}
-{if $user->canManageTeam() || $user->isClient()}
+{if $user->can('view_reports') || $user->can('view_all_reports') || $user->isClient()}
         <tr>
           <td colspan="3"><b>{$i18n.label.users}</b></td>
         </tr>
@@ -248,18 +248,18 @@ function handleCheckboxes() {
         <tr>
           <td colspan="3">
             <table border="0" width="100%">
-{if $user->canManageTeam() || $user->isPluginEnabled('cl') || $user->isPluginEnabled('iv') || $user->isPluginEnabled('ps')}
+{if $user->can('view_reports') || $user->can('view_all_reports') || $user->isPluginEnabled('cl') || $user->isPluginEnabled('iv') || $user->isPluginEnabled('ps')}
               <tr>
   {if $user->isPluginEnabled('cl')}
                 <td width="25%"><label>{$forms.reportForm.chclient.control}&nbsp;{$i18n.label.client}</label></td>
   {/if}
-  {if ($user->canManageTeam() || $user->isClient()) && $user->isPluginEnabled('iv')}
+  {if ($user->can('manage_invoices') || $user->isClient()) && $user->isPluginEnabled('iv')}
                 <td width="25%"><label>{$forms.reportForm.chinvoice.control}&nbsp;{$i18n.label.invoice}</label></td>
   {/if}
-  {if ($user->canManageTeam() && $user->isPluginEnabled('ps'))}
+  {if ($user->can('manage_invoices') && $user->isPluginEnabled('ps'))}
                 <td width="25%"><label>{$forms.reportForm.chpaid.control}&nbsp;{$i18n.label.paid}</label></td>
   {/if}
-  {if $user->canManageTeam()}
+  {if $user->can('view_reports') || $user->can('view_all_reports')}
                 <td width="25%"><label>{$forms.reportForm.chip.control}&nbsp;{$i18n.label.ip}</label></td>
   {/if}
               </tr>