mail versand wip
This commit is contained in:
1 parent
e1f7729add
commit
ebdf2e396a
32 files changed
+496
-28
No files matched your search
@@ -0,0 +1,43 @@
|
||||
<?php
|
||||
|
||||
namespace App\Filament\Resources\MailVersands\Tables;
|
||||
|
||||
use Filament\Actions\EditAction;
|
||||
use Filament\Tables\Columns\SelectColumn;
|
||||
use Filament\Tables\Columns\TextColumn;
|
||||
use Filament\Tables\Columns\ToggleColumn;
|
||||
use Filament\Tables\Table;
|
||||
|
||||
class MailVersandsTable
|
||||
{
|
||||
public static function configure(Table $table): Table
|
||||
{
|
||||
return $table
|
||||
->columns([
|
||||
TextColumn::make('name')->label('Benennung'),
|
||||
SelectColumn::make('mail_gruppen_id')
|
||||
->optionsRelationship(name: 'mail_gruppen', titleAttribute: 'name')
|
||||
->label('Versand an Gruppe'),
|
||||
SelectColumn::make('mail_vorlage_id')
|
||||
->optionsRelationship(name: 'mail_vorlage', titleAttribute: 'titel')
|
||||
->label('Vorlage'),
|
||||
TextColumn::make('sende_zeitpunkt')->dateTime()->label('Sende Zeitpunkt'),
|
||||
TextColumn::make('versand_am')->dateTime(),
|
||||
SelectColumn::make('status')
|
||||
->native(false)
|
||||
->disabled(fn ($record): bool => $record->ist_active ? true : false)
|
||||
->options([
|
||||
'wartend' => '<span class="text-blue-500">Wartend</span>',
|
||||
'versand' => '<span class="text-green-500">Mail Versand</span>',
|
||||
])
|
||||
->allowOptionsHtml(),
|
||||
ToggleColumn::make('ist_active')->onColor('success'),
|
||||
])
|
||||
->filters([
|
||||
//
|
||||
])
|
||||
->recordActions([
|
||||
EditAction::make()->iconButton(),
|
||||
]);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user