From f56e9c534c655c7556b1e30d8e5a53e79c3c1960 Mon Sep 17 00:00:00 2001 From: Igor Scheller Date: Sun, 18 Feb 2024 01:50:15 +0100 Subject: [PATCH] Add title to "Enough" goodie score --- includes/controller/users_controller.php | 5 ++--- includes/view/User_view.php | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/includes/controller/users_controller.php b/includes/controller/users_controller.php index c6dab7fd..6f7b900b 100644 --- a/includes/controller/users_controller.php +++ b/includes/controller/users_controller.php @@ -239,10 +239,9 @@ function user_controller() auth()->resetApiKey($user_source); } + $tshirt_score = sprintf('%.2f', User_tshirt_score($user_source->id)) . ' h'; if ($user_source->state->force_active && config('enable_force_active')) { - $tshirt_score = __('Enough'); - } else { - $tshirt_score = sprintf('%.2f', User_tshirt_score($user_source->id)) . ' h'; + $tshirt_score = '' . __('Enough') . ''; } $worklogs = $user_source->worklogs() diff --git a/includes/view/User_view.php b/includes/view/User_view.php index 2e3af5fd..27fa6197 100644 --- a/includes/view/User_view.php +++ b/includes/view/User_view.php @@ -414,7 +414,7 @@ function User_view_myshift(Shift $shift, $user_source, $its_me) * @param Shift[]|Collection $shifts * @param User $user_source * @param bool $its_me - * @param int $tshirt_score + * @param string $tshirt_score * @param bool $tshirt_admin * @param Worklog[]|Collection $user_worklogs * @param bool $admin_user_worklog_privilege @@ -549,7 +549,7 @@ function User_view_worklog(Worklog $worklog, $admin_user_worklog_privilege) * @param Group[] $user_groups * @param Shift[]|Collection $shifts * @param bool $its_me - * @param int $tshirt_score + * @param string $tshirt_score * @param bool $tshirt_admin * @param bool $admin_user_worklog_privilege * @param Worklog[]|Collection $user_worklogs