- Gäste, Buchungen (Status-Workflow), Sperrzeiten, Sonderangebote - Vorreservierung mit Haltezeit je Wohnung; abgelaufene Holds geben den Kalender sofort frei, Cron setzt Status und benachrichtigt - Sonderangebote/Sonderkonditionen: %, € pro Aufenthalt, Sonderpreis/Nacht, Gratis-Nächte; Bedingungen u. a. Saison, Vorlauf, Wochentag, Nächte, Aktionscode; bestes Einzel- vs. kombinierte Angebote - Öffentliche Seite /buchen: Belegungskalender, Live-Preis, Anfrageformular (Honeypot, Rate-Limit) - E-Mails: Angebot an Gast, Benachrichtigung Vermieter, Bestätigung, Absage, Ablauf - Filament: Anfragen & Buchungen (bestätigen, ablehnen, verlängern, stornieren, Telefonbuchung), Gäste, Sperrzeiten, Sonderangebote - Deutsche Validierungstexte Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
57 lines
1.4 KiB
PHP
57 lines
1.4 KiB
PHP
<?php
|
|
|
|
namespace App\Filament\Resources\Guests;
|
|
|
|
use App\Filament\Resources\Guests\Pages\CreateGuest;
|
|
use App\Filament\Resources\Guests\Pages\EditGuest;
|
|
use App\Filament\Resources\Guests\Pages\ListGuests;
|
|
use App\Filament\Resources\Guests\Schemas\GuestForm;
|
|
use App\Filament\Resources\Guests\Tables\GuestsTable;
|
|
use App\Models\Guest;
|
|
use BackedEnum;
|
|
use Filament\Resources\Resource;
|
|
use Filament\Schemas\Schema;
|
|
use Filament\Support\Icons\Heroicon;
|
|
use Filament\Tables\Table;
|
|
|
|
class GuestResource extends Resource
|
|
{
|
|
protected static ?string $model = Guest::class;
|
|
|
|
protected static string|BackedEnum|null $navigationIcon = Heroicon::OutlinedUsers;
|
|
|
|
protected static ?string $modelLabel = 'Gast';
|
|
|
|
protected static ?string $pluralModelLabel = 'Gäste';
|
|
|
|
protected static ?string $recordTitleAttribute = 'last_name';
|
|
|
|
protected static ?int $navigationSort = 2;
|
|
|
|
public static function form(Schema $schema): Schema
|
|
{
|
|
return GuestForm::configure($schema);
|
|
}
|
|
|
|
public static function table(Table $table): Table
|
|
{
|
|
return GuestsTable::configure($table);
|
|
}
|
|
|
|
public static function getRelations(): array
|
|
{
|
|
return [
|
|
//
|
|
];
|
|
}
|
|
|
|
public static function getPages(): array
|
|
{
|
|
return [
|
|
'index' => ListGuests::route('/'),
|
|
'create' => CreateGuest::route('/create'),
|
|
'edit' => EditGuest::route('/{record}/edit'),
|
|
];
|
|
}
|
|
}
|