Neustrukturierung Customer / Lead / Booking Phase 2

This commit is contained in:
Kevin Adametz 2026-05-28 17:10:37 +02:00
parent 313f0dbf4e
commit 6df9c401af
69 changed files with 3809 additions and 374 deletions

View file

@ -0,0 +1,31 @@
<?php
namespace App\Events\Offer;
use App\Models\Offer;
use App\Models\OfferAccessToken;
use App\Models\OfferVersion;
use Illuminate\Foundation\Events\Dispatchable;
/**
* Wird gefeuert, nachdem eine OfferVersion status=sent gesetzt wurde und ein
* frischer Access-Token existiert. Listener (Ticket B6) versenden die Mail,
* schreiben das Kommunikations-Log und fügen den öffentlichen Link ein.
*
* Der Mail-Plaintext-Token liegt in `$token->plain_token` wird NUR hier,
* beim Versand, in den Link eingebaut. Nach dem Event wird die Property
* wieder entsorgt.
*/
class OfferSent
{
use Dispatchable;
public function __construct(
public readonly Offer $offer,
public readonly OfferVersion $version,
public readonly OfferAccessToken $token,
/** @var array<string,mixed> Betreff/Body/CC aus dem Versand-Modal. */
public readonly array $mailData = [],
) {
}
}