Update SettingsTable to conditionally display group column: Re-enabled the group column with visibility control based on the active tab, while maintaining localization support for the column labels.
This commit is contained in:
@@ -58,13 +58,14 @@ class SettingsTable
|
|||||||
default => 'gray',
|
default => 'gray',
|
||||||
})
|
})
|
||||||
->formatStateUsing(fn (string $state): string => __("settings.type_{$state}")),
|
->formatStateUsing(fn (string $state): string => __("settings.type_{$state}")),
|
||||||
/*
|
|
||||||
TextColumn::make('group')
|
TextColumn::make('group')
|
||||||
->label(__('settings.table_group'))
|
->label(__('settings.table_group'))
|
||||||
->badge()
|
->badge()
|
||||||
->color('primary')
|
->color('primary')
|
||||||
|
->visible(fn ($livewire) => $livewire->activeTab === 'all')
|
||||||
->formatStateUsing(fn (string $state): string => __("settings.group_{$state}")),
|
->formatStateUsing(fn (string $state): string => __("settings.group_{$state}")),
|
||||||
*/
|
|
||||||
IconColumn::make('is_active')
|
IconColumn::make('is_active')
|
||||||
->label(__('settings.table_active'))
|
->label(__('settings.table_active'))
|
||||||
->boolean()
|
->boolean()
|
||||||
|
|||||||
Reference in New Issue
Block a user