From: anuko Date: Wed, 21 Sep 2016 01:52:33 +0000 (+0000) Subject: Work in progress adding checks for enabled plugins for pages. X-Git-Tag: timetracker_1.19-1~1640 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=5fdf8659516ad2b07458deba8eda234e8e07c554;p=timetracker.git Work in progress adding checks for enabled plugins for pages. --- diff --git a/WEB-INF/templates/charts.tpl b/WEB-INF/templates/charts.tpl index 22238715..4c676147 100644 --- a/WEB-INF/templates/charts.tpl +++ b/WEB-INF/templates/charts.tpl @@ -35,5 +35,3 @@ {$forms.chartForm.date.control} {$forms.chartForm.close} - - diff --git a/WEB-INF/templates/header.tpl b/WEB-INF/templates/header.tpl index ce8e229c..b307f4c8 100644 --- a/WEB-INF/templates/header.tpl +++ b/WEB-INF/templates/header.tpl @@ -27,7 +27,7 @@ With 101% height we essentially force the scrollbar to always appear. --> - + {if $user->custom_logo} @@ -54,11 +54,11 @@ With 101% height we essentially force the scrollbar to always appear. -->
- + {if $authenticated} {if $user->isAdmin()} - +
  @@ -68,9 +68,9 @@ With 101% height we essentially force the scrollbar to always appear. -->
- + - +
  @@ -79,9 +79,9 @@ With 101% height we essentially force the scrollbar to always appear. -->
- + {else} - +
  @@ -92,9 +92,9 @@ With 101% height we essentially force the scrollbar to always appear. -->
- + - +
  @@ -130,10 +130,10 @@ With 101% height we essentially force the scrollbar to always appear. -->
- + {/if} {else} - +
  @@ -149,16 +149,16 @@ With 101% height we essentially force the scrollbar to always appear. --> {/if}
- + {if $title}
{$title}{if $timestring}: {$timestring}{/if}
{$user->name|escape:'html'}{if $user->isAdmin()} {$i18n.label.role_admin}{elseif $user->isManager()} {$i18n.label.role_manager}{elseif $user->canManageTeam()} {$i18n.label.role_comanager}{/if}{if $user->behalf_id > 0} {$i18n.label.on_behalf} {$user->behalf_name|escape:'html'}{/if}{if $user->team}, {$user->team|escape:'html'}{/if}
{/if} - + - + {if $err->yes()} @@ -170,9 +170,9 @@ With 101% height we essentially force the scrollbar to always appear. -->
{/if} - + - + {if $msg->yes()} @@ -184,4 +184,4 @@ With 101% height we essentially force the scrollbar to always appear. -->
{/if} - + diff --git a/WEB-INF/templates/mobile/header.tpl b/WEB-INF/templates/mobile/header.tpl index cd266aeb..7a48f5e9 100644 --- a/WEB-INF/templates/mobile/header.tpl +++ b/WEB-INF/templates/mobile/header.tpl @@ -25,7 +25,7 @@
- + {if $user->custom_logo} @@ -52,12 +52,12 @@
- + {if $authenticated} {if $user->isAdmin()} - +
  @@ -66,10 +66,10 @@
- + {else} - +
  @@ -94,11 +94,11 @@
- + {/if} {/if} - + {if $err->yes()} @@ -110,9 +110,9 @@
{/if} - + - + {if $msg->yes()} @@ -124,4 +124,4 @@
{/if} - + diff --git a/charts.php b/charts.php index 9dec840a..3ef76e52 100644 --- a/charts.php +++ b/charts.php @@ -38,7 +38,7 @@ import('ttUserHelper'); import('ttTeamHelper'); // Access check. -if (!ttAccessCheck(right_view_charts)) { +if (!ttAccessCheck(right_view_charts) || !$user->isPluginEnabled('ch')) { header('Location: access_denied.php'); exit(); } diff --git a/clients.php b/clients.php index 6dcfe4a5..0a027b8b 100644 --- a/clients.php +++ b/clients.php @@ -31,7 +31,7 @@ import('form.Form'); import('ttTeamHelper'); // Access check. -if (!ttAccessCheck(right_manage_team)) { +if (!ttAccessCheck(right_manage_team) || !$user->isPluginEnabled('cl')) { header('Location: access_denied.php'); exit(); } diff --git a/expenses.php b/expenses.php index 4c2b7b27..0f4265aa 100644 --- a/expenses.php +++ b/expenses.php @@ -34,7 +34,7 @@ import('DateAndTime'); import('ttExpenseHelper'); // Access check. -if (!ttAccessCheck(right_data_entry)) { +if (!ttAccessCheck(right_data_entry) || !$user->isPluginEnabled('ex')) { header('Location: access_denied.php'); exit(); } diff --git a/mobile/clients.php b/mobile/clients.php index d6ebbe40..6312c2dd 100644 --- a/mobile/clients.php +++ b/mobile/clients.php @@ -31,7 +31,7 @@ import('form.Form'); import('ttTeamHelper'); // Access check. -if (!ttAccessCheck(right_manage_team)) { +if (!ttAccessCheck(right_manage_team) || !$user->isPluginEnabled('cl')) { header('Location: access_denied.php'); exit(); } diff --git a/mobile/expenses.php b/mobile/expenses.php index 4246f589..fafe1373 100644 --- a/mobile/expenses.php +++ b/mobile/expenses.php @@ -34,7 +34,7 @@ import('DateAndTime'); import('ttExpenseHelper'); // Access check. -if (!ttAccessCheck(right_data_entry)) { +if (!ttAccessCheck(right_data_entry) || !$user->isPluginEnabled('ex')) { header('Location: access_denied.php'); exit(); }