add column '2fa status' for customers and admins

Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann
2024-07-20 23:26:53 +02:00
parent 2dae780e0b
commit 4d3cf5da9a
7 changed files with 34 additions and 0 deletions

View File

@@ -52,6 +52,14 @@ class Text
];
}
public static function type2fa(array $attributes): array
{
return [
'macro' => 'type2fa',
'data' => (int)$attributes['data']
];
}
public static function customerfullname(array $attributes): string
{
return User::getCorrectFullUserDetails($attributes['fields'], true);

View File

@@ -110,6 +110,12 @@ return [
'class' => 'text-center',
'callback' => [Text::class, 'boolean'],
],
'type_2fa' => [
'label' => lng('2fa.type_2fa'),
'field' => 'type_2fa',
'class' => 'text-center',
'callback' => [Text::class, 'type2fa'],
],
],
'visible_columns' => Listing::getVisibleColumnsForListing('admin_list', [
'loginname',

View File

@@ -149,6 +149,12 @@ return [
'class' => 'text-center',
'callback' => [Text::class, 'boolean'],
],
'c.type_2fa' => [
'label' => lng('2fa.type_2fa'),
'field' => 'type_2fa',
'class' => 'text-center',
'callback' => [Text::class, 'type2fa'],
],
],
'visible_columns' => Listing::getVisibleColumnsForListing('customer_list', [
'c.name',