wip matches

This commit is contained in:
salam committed 2025-08-27 12:51:03 +02:00
1 parent adb15e701b
commit 7116d3c576
33 files changed
+379 -176

No files matched your search

@@ -8,6 +8,7 @@ use App\Models\Sport;
use BackedEnum;
use Filament\Resources\Resource;
use Filament\Schemas\Schema;
use Filament\Support\Enums\IconSize;
use Filament\Tables\Columns\IconColumn;
use Filament\Tables\Columns\TextColumn;
use Filament\Tables\Columns\ToggleColumn;
@@ -43,21 +44,16 @@ class SportResource extends Resource
->columns([
IconColumn::make('icon')
->label('')
->size(IconSize::TwoExtraLarge)
->icon(function ($record): string {
return $record->icon;
})->color(function ($record): string {
if ($record->is_active == 1) {
return 'primary';
} else {
return 'gray';
}
}),
TextColumn::make('name'),
TextColumn::make('bapi'),
TextColumn::make('bwin'),
TextColumn::make('b365'),
TextColumn::make('logi'),
TextColumn::make('magl'),
TextColumn::make('bapi')->alignCenter()->label('Betsapi'),
TextColumn::make('bwin')->alignCenter()->label('Bwin'),
TextColumn::make('b365')->alignCenter()->label('Bet365'),
TextColumn::make('logi')->alignCenter()->label('Logifuture'),
TextColumn::make('magl')->alignCenter()->label('Magloo'),
ToggleColumn::make('is_active'),
])
->filters([
@@ -25,7 +25,7 @@ class SupervisorForm
'Grapper' => 'Grapper',
'Comparatore' => 'Comparatore',
])
->default('grapper')
->default('Grapper')
->selectablePlaceholder(false),
Select::make('provider_id')
->relationship('provider', 'name')
@@ -18,8 +18,7 @@ class SupervisorsTable
return $table
->columns([
TextColumn::make('id')->badge(),
TextColumn::make('name')
->searchable(),
TextColumn::make('name')->searchable(),
TextColumn::make('type')->badge(),
TextColumn::make('provider.name')
->badge()->color(fn (string $state): string => match ($state) {
@@ -40,7 +39,6 @@ class SupervisorsTable
TextColumn::make('runtime'),
TextColumn::make('lastcall'),
IconColumn::make('is_cron')->boolean()->label('Cron')->falseColor('gray'),
ToggleColumn::make('is_active')->label('On/Off'),
TextColumn::make('created_at')
->dateTime()
->sortable()
@@ -49,6 +47,7 @@ class SupervisorsTable
->dateTime()
->sortable()
->toggleable(isToggledHiddenByDefault: true),
ToggleColumn::make('is_active')->label('On/Off'),
])
->filters([
//