Phase 2: Kalender, Anfrage, Vorreservierung & Sonderangebote

- 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>
This commit is contained in:
Lars StommerandClaude Opus 5.5 committed 2026-10-22 09:43:12 +02:00
1 parent 2e9a391b37
commit 08b6582fa1
79 files changed
+6213 -76

No files matched your search

+32
View File
@@ -0,0 +1,32 @@
<?php
namespace App\Actions;
use App\Enums\BookingStatus;
use App\Mail\ReservationExpired;
use App\Models\Booking;
use Illuminate\Support\Facades\Mail;
/**
* Marks reservations whose hold time is over as expired and tells the landlord.
* The calendar already treats them as free once the hold time is over; this only updates the status.
*/
class ExpireReservations
{
public function handle(): int
{
$expired = Booking::query()
->where('status', BookingStatus::Reserved)
->where('hold_expires_at', '<=', now())
->with(['guest', 'property'])
->get();
foreach ($expired as $booking) {
$booking->update(['status' => BookingStatus::Expired]);
Mail::to(config('fewo.notification_email'))->send(new ReservationExpired($booking));
}
return $expired->count();
}
}