absender wip
This commit is contained in:
1 parent
ebdf2e396a
commit
0b4a070c33
5 files changed
+28
-12
No files matched your search
@@ -12,6 +12,8 @@ class MailGruppenForm
|
|||||||
return $schema
|
return $schema
|
||||||
->components([
|
->components([
|
||||||
TextInput::make('name'),
|
TextInput::make('name'),
|
||||||
|
TextInput::make('absender_name')->label('Absender Name'),
|
||||||
|
TextInput::make('absender_mail')->label('Absender E-Mail'),
|
||||||
])->columns(1);
|
])->columns(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -4,6 +4,7 @@ namespace App\Filament\Resources\MailGruppens\Tables;
|
|||||||
|
|
||||||
use Filament\Actions\DeleteAction;
|
use Filament\Actions\DeleteAction;
|
||||||
use Filament\Actions\EditAction;
|
use Filament\Actions\EditAction;
|
||||||
|
use Filament\Support\Icons\Heroicon;
|
||||||
use Filament\Tables\Columns\TextColumn;
|
use Filament\Tables\Columns\TextColumn;
|
||||||
use Filament\Tables\Table;
|
use Filament\Tables\Table;
|
||||||
|
|
||||||
@@ -14,7 +15,12 @@ class MailGruppensTable
|
|||||||
return $table
|
return $table
|
||||||
->columns([
|
->columns([
|
||||||
TextColumn::make('id'),
|
TextColumn::make('id'),
|
||||||
TextColumn::make('name'),
|
TextColumn::make('name')->label('Bezeichnung'),
|
||||||
|
TextColumn::make('absender_name')->label('Absender Name'),
|
||||||
|
TextColumn::make('absender_mail')
|
||||||
|
->icon(Heroicon::Envelope)
|
||||||
|
->iconColor('primary')
|
||||||
|
->label('Absender E-Mail'),
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
EditAction::make()->iconButton(),
|
EditAction::make()->iconButton(),
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
namespace App\Filament\Resources\MailVersands\Tables;
|
namespace App\Filament\Resources\MailVersands\Tables;
|
||||||
|
|
||||||
|
use Filament\Actions\Action;
|
||||||
use Filament\Actions\EditAction;
|
use Filament\Actions\EditAction;
|
||||||
use Filament\Tables\Columns\SelectColumn;
|
use Filament\Tables\Columns\SelectColumn;
|
||||||
use Filament\Tables\Columns\TextColumn;
|
use Filament\Tables\Columns\TextColumn;
|
||||||
@@ -21,22 +22,25 @@ class MailVersandsTable
|
|||||||
SelectColumn::make('mail_vorlage_id')
|
SelectColumn::make('mail_vorlage_id')
|
||||||
->optionsRelationship(name: 'mail_vorlage', titleAttribute: 'titel')
|
->optionsRelationship(name: 'mail_vorlage', titleAttribute: 'titel')
|
||||||
->label('Vorlage'),
|
->label('Vorlage'),
|
||||||
TextColumn::make('sende_zeitpunkt')->dateTime()->label('Sende Zeitpunkt'),
|
TextColumn::make('sende_zeitpunkt')
|
||||||
TextColumn::make('versand_am')->dateTime(),
|
->since()
|
||||||
SelectColumn::make('status')
|
->dateTooltip()
|
||||||
->native(false)
|
->label('Sende Zeitpunkt'),
|
||||||
->disabled(fn ($record): bool => $record->ist_active ? true : false)
|
TextColumn::make('versand_am')
|
||||||
->options([
|
->since()
|
||||||
'wartend' => '<span class="text-blue-500">Wartend</span>',
|
->dateTooltip(),
|
||||||
'versand' => '<span class="text-green-500">Mail Versand</span>',
|
ToggleColumn::make('ist_active')
|
||||||
])
|
->label('Senden')
|
||||||
->allowOptionsHtml(),
|
->tooltip('Wenn aktive wird der Newsletter zum eingestellten Zeitpunkt versand'),
|
||||||
ToggleColumn::make('ist_active')->onColor('success'),
|
|
||||||
])
|
])
|
||||||
->filters([
|
->filters([
|
||||||
//
|
//
|
||||||
])
|
])
|
||||||
->recordActions([
|
->recordActions([
|
||||||
|
Action::make('testmail')
|
||||||
|
->color('warning')
|
||||||
|
->iconButton()
|
||||||
|
->icon('heroicon-s-paper-airplane'),
|
||||||
EditAction::make()->iconButton(),
|
EditAction::make()->iconButton(),
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,5 +8,7 @@ class MailGruppen extends Model
|
|||||||
{
|
{
|
||||||
protected $fillable = [
|
protected $fillable = [
|
||||||
'name',
|
'name',
|
||||||
|
'absender_name',
|
||||||
|
'absender_mail',
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
@@ -14,6 +14,8 @@ return new class extends Migration
|
|||||||
Schema::create('mail_gruppens', function (Blueprint $table) {
|
Schema::create('mail_gruppens', function (Blueprint $table) {
|
||||||
$table->id();
|
$table->id();
|
||||||
$table->string('name');
|
$table->string('name');
|
||||||
|
$table->string('absender_name');
|
||||||
|
$table->string('absender_mail');
|
||||||
$table->timestamps();
|
$table->timestamps();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user