Portal-Direktbuchung erfassen, Kontaktdaten-Prozess, manueller Statuswechsel, Archiv, Filter, Menue Verwaltung/Einrichtung
Deploy FeWo mit PipelineManager / deploy (push) Successful in 3m38s
Deploy FeWo mit PipelineManager / deploy (push) Successful in 3m38s
- Buchung erfassen: Buchungsweg Portal (Referenz, Portalpreis, ohne Kontaktdaten), Prozess bestaetigen/Vertrag sofort/nur erfassen - Buchungsakte: Kontaktdaten eintragen (automatisch oder manuell weiter), Gast um Kontaktdaten bitten, Status von Hand aendern, Archivieren - Liste: Filter Kanal, Anreisezeitraum, Kontaktdaten fehlen; Spalten ausblendbar; Archiv - Klaerung: verstaendlichere Texte, eigenstaendige Belegung mit Kanal gilt als geklaert (Gitea #4) - Akte per Button aus Liste und Belegungsplan erreichbar - Menue: Gruppen Verwaltung (Tagesgeschaeft) und Einrichtung (Konfiguration), einfache Ansicht auf 8 Punkte Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
0c4187edaf
commit
5ba9ae08ab
37 files changed
+786
-82
No files matched your search
@@ -2,18 +2,24 @@
|
||||
|
||||
namespace App\Filament\Resources\Bookings\Schemas;
|
||||
|
||||
use App\Actions\RecordPortalBooking;
|
||||
use App\Filament\Forms\Components\EuroInput;
|
||||
use App\Models\Channel;
|
||||
use App\Models\Property;
|
||||
use App\Support\CurrentProperty;
|
||||
use Filament\Forms\Components\DatePicker;
|
||||
use Filament\Forms\Components\Radio;
|
||||
use Filament\Forms\Components\Select;
|
||||
use Filament\Forms\Components\Textarea;
|
||||
use Filament\Forms\Components\TextInput;
|
||||
use Filament\Forms\Components\Toggle;
|
||||
use Filament\Schemas\Components\Section;
|
||||
use Filament\Schemas\Components\Utilities\Get;
|
||||
use Filament\Schemas\Schema;
|
||||
|
||||
/**
|
||||
* Manual entry of a booking received by phone or e-mail. The price is calculated automatically.
|
||||
* Manual entry of a booking received by phone or e-mail, or made binding by a portal (e.g. FeWo-direkt, usually
|
||||
* without the guest's contact data). The price is calculated automatically; a portal price can be entered.
|
||||
*/
|
||||
class BookingForm
|
||||
{
|
||||
@@ -28,7 +34,8 @@ public static function configure(Schema $schema): Schema
|
||||
->label('Wohnung')
|
||||
->options(fn (): array => Property::query()->orderBy('name')->pluck('name', 'id')->all())
|
||||
->default(fn (): ?int => app(CurrentProperty::class)->id())
|
||||
->required(),
|
||||
->required()
|
||||
->live(),
|
||||
TextInput::make('guests')
|
||||
->label('Personen')
|
||||
->integer()
|
||||
@@ -45,12 +52,25 @@ public static function configure(Schema $schema): Schema
|
||||
TextInput::make('promo_code')
|
||||
->label('Aktionscode'),
|
||||
]),
|
||||
Section::make('Buchungsweg')
|
||||
->description('Telefon oder E-Mail: nichts auswählen. Hat ein Portal die Buchung bereits verbindlich gemacht (z. B. FeWo-direkt), das Portal wählen – dann genügen Name und Zeitraum, die Kontaktdaten können später nachgetragen werden.')
|
||||
->columns(2)
|
||||
->schema([
|
||||
Select::make('channel_id')
|
||||
->label('Über Portal')
|
||||
->placeholder('Direkt / telefonisch / per E-Mail')
|
||||
->options(fn (Get $get): array => Channel::query()->where('property_id', $get('property_id'))->orderBy('name')->pluck('name', 'id')->all())
|
||||
->live(),
|
||||
TextInput::make('portal_reference')->label('Referenz im Portal (Buchungsnummer)')->maxLength(100)->visible(fn (Get $get): bool => filled($get('channel_id'))),
|
||||
EuroInput::make('portal_total')->label('Preis laut Portal (Gesamtpreis, optional)')->helperText('Weicht er von unserer Berechnung ab, wird die Differenz als Zeile „Abweichung Portalpreis“ geführt.')->visible(fn (Get $get): bool => filled($get('channel_id'))),
|
||||
]),
|
||||
Section::make('Gast')
|
||||
->description(fn (Get $get): ?string => filled($get('channel_id')) ? 'Bei Portalbuchungen ohne Kontaktdaten genügt der Name – E-Mail und Adresse können später ergänzt werden.' : null)
|
||||
->columns(2)
|
||||
->schema([
|
||||
TextInput::make('first_name')->label('Vorname')->required()->maxLength(255),
|
||||
TextInput::make('last_name')->label('Nachname')->required()->maxLength(255),
|
||||
TextInput::make('email')->label('E-Mail')->email()->required()->maxLength(255),
|
||||
TextInput::make('email')->label('E-Mail')->email()->required(fn (Get $get): bool => blank($get('channel_id')))->maxLength(255),
|
||||
TextInput::make('phone')->label('Telefon')->tel()->maxLength(50),
|
||||
TextInput::make('street')->label('Straße')->maxLength(255),
|
||||
TextInput::make('postal_code')->label('PLZ')->maxLength(20),
|
||||
@@ -59,8 +79,19 @@ public static function configure(Schema $schema): Schema
|
||||
Section::make('Abschluss')
|
||||
->schema([
|
||||
Textarea::make('internal_notes')->label('Interne Notiz'),
|
||||
Toggle::make('confirm_immediately')->label('Sofort verbindlich bestätigen')->default(true),
|
||||
Toggle::make('send_mails')->label('E-Mails an den Gast senden')->default(false),
|
||||
Toggle::make('confirm_immediately')->label('Sofort verbindlich bestätigen')->default(true)->visible(fn (Get $get): bool => blank($get('channel_id'))),
|
||||
Toggle::make('send_mails')->label('E-Mails an den Gast senden')->default(false)->visible(fn (Get $get): bool => blank($get('channel_id'))),
|
||||
Radio::make('portal_process')
|
||||
->label('Wie geht der Vertragsprozess weiter?')
|
||||
->options([
|
||||
RecordPortalBooking::CONFIRM => 'Buchung bestätigen (Zeitraum belegen), Vertrag später – sobald die Kontaktdaten da sind',
|
||||
RecordPortalBooking::CONTRACT => 'Buchung bestätigen und Vertrag jetzt per E-Mail senden (E-Mail-Adresse nötig)',
|
||||
RecordPortalBooking::RECORD => 'Nur als Anfrage erfassen – alles Weitere von Hand',
|
||||
])
|
||||
->default(RecordPortalBooking::CONFIRM)
|
||||
->required(fn (Get $get): bool => filled($get('channel_id')))
|
||||
->visible(fn (Get $get): bool => filled($get('channel_id'))),
|
||||
Toggle::make('guest_confirmed')->label('Der Gast hat die Buchung bereits per E-Mail bestätigt')->visible(fn (Get $get): bool => filled($get('channel_id'))),
|
||||
]),
|
||||
]);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user