From 2bd9983978cf8d6263e27a531aeb33f365667e37 Mon Sep 17 00:00:00 2001 From: Nik Okuntseff Date: Sat, 14 Apr 2018 13:07:37 +0000 Subject: [PATCH] Some more refactoring. --- WEB-INF/templates/footer.tpl | 2 +- WEB-INF/templates/reports.tpl | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/WEB-INF/templates/footer.tpl b/WEB-INF/templates/footer.tpl index 3ff2dda3..16befd9a 100644 --- a/WEB-INF/templates/footer.tpl +++ b/WEB-INF/templates/footer.tpl @@ -12,7 +12,7 @@
- {/if} -{if $user->canManageTeam() || $user->isClient()} +{if $user->can('view_reports') || $user->can('view_all_reports') || $user->isClient()} @@ -248,18 +248,18 @@ function handleCheckboxes() {
 Anuko Time Tracker 1.17.88.4266 | Copyright © Anuko | +  Anuko Time Tracker 1.17.88.4267 | Copyright © Anuko | {$i18n.footer.credits} | {$i18n.footer.license} | {$i18n.footer.improve} diff --git a/WEB-INF/templates/reports.tpl b/WEB-INF/templates/reports.tpl index 8aa7f6de..a70a3f07 100644 --- a/WEB-INF/templates/reports.tpl +++ b/WEB-INF/templates/reports.tpl @@ -221,7 +221,7 @@ function handleCheckboxes() { {$forms.reportForm.paid_status.control}
{$i18n.label.users}
-{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')} {if $user->isPluginEnabled('cl')} {/if} - {if ($user->canManageTeam() || $user->isClient()) && $user->isPluginEnabled('iv')} + {if ($user->can('manage_invoices') || $user->isClient()) && $user->isPluginEnabled('iv')} {/if} - {if ($user->canManageTeam() && $user->isPluginEnabled('ps'))} + {if ($user->can('manage_invoices') && $user->isPluginEnabled('ps'))} {/if} - {if $user->canManageTeam()} + {if $user->can('view_reports') || $user->can('view_all_reports')} {/if} -- 2.20.1