diff --git a/config/config.default.php b/config/config.default.php index f438f507..ce261089 100644 --- a/config/config.default.php +++ b/config/config.default.php @@ -285,6 +285,9 @@ return [ // Number of shifts to freeload until angel is locked for shift signup. 'max_freeloadable_shifts' => env('MAX_FREELOADABLE_SHIFTS', 2), + // Hide columns in backend user view. Possible values are any sortable parameters of the table. + 'disabled_user_view_columns' => [], + // Local timezone 'timezone' => env('TIMEZONE', 'Europe/Berlin'), diff --git a/includes/view/User_view.php b/includes/view/User_view.php index 0fcf7371..b1c48683 100644 --- a/includes/view/User_view.php +++ b/includes/view/User_view.php @@ -158,6 +158,10 @@ function Users_view( $user_table_headers['last_login_at'] = Users_table_header_link('last_login_at', __('Last login'), $order_by); $user_table_headers['actions'] = ''; + foreach (config('disabled_user_view_columns') ?? [] as $key) { + unset($user_table_headers[$key]); + } + return page_with_title(__('All users'), [ msg(), buttons([