X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=week.php;h=05d399214d4d8e8677121006859f1a72d3a3442a;hb=1078c4da84d79f93ef7f8bbffc5f0c8cb2a1a274;hp=af5b9eb06947581aad0cb54b6267455572239186;hpb=a26a0989ad93cce9de9f45312990da9610e53045;p=timetracker.git diff --git a/week.php b/week.php index af5b9eb0..05d39921 100644 --- a/week.php +++ b/week.php @@ -57,6 +57,7 @@ if (!$user->behalf_id && !$user->can('track_own_time') && !$user->adjustBehalfId } // End of access checks. +$showClient = $user->isPluginEnabled('cl'); $showFiles = $user->isPluginEnabled('at'); // Initialize and store date in session. @@ -348,7 +349,7 @@ if ($request->isPost()) { } } if ($newEntryPosted) { - if ($user->isPluginEnabled('cl') && $user->isPluginEnabled('cm') && !$cl_client) + if ($user->isPluginEnabled('cl') && $user->isOptionEnabled('client_required') && !$cl_client) $err->add($i18n->get('error.client')); if ($custom_fields) { if (!ttValidString($cl_cf_1, !$custom_fields->fields[0]['required'])) $err->add($i18n->get('error.field'), $custom_fields->fields[0]['label']); @@ -509,7 +510,8 @@ $smarty->assign('onload', 'onLoad="fillDropdowns()"'); $smarty->assign('timestring', $startDate->toString($user->date_format).' - '.$endDate->toString($user->date_format)); $smarty->assign('time_records', $records); $smarty->assign('show_navigation', !$user->getConfigOption('menu_week')); +$smarty->assign('show_client', $showClient); $smarty->assign('show_files', $showFiles); -$smarty->assign('title', $i18n->get('title.time')); +$smarty->assign('title', $i18n->get('menu.week')); $smarty->assign('content_page_name', 'week.tpl'); $smarty->display('index.tpl');