File: D:/HostingSpaces/SBogers10/farmfun.komma.pro/app/Mail/ClientInformationMail.php
<?php
namespace App\Mail;
use App\Komma\Reservations\Models\Reservation;
use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;
use Illuminate\Support\Facades\URL;
class ClientInformationMail extends Mailable
{
use Queueable, SerializesModels;
/** @var Reservation */
private Reservation $reservation;
private string $reservationInformationUrl;
/**
* Create a new message instance.
*
* @return void
*/
public function __construct(Reservation $reservation)
{
$this->reservation = $reservation;
$this->reservationInformationUrl = URL::signedRoute('reservation.information', ['reservation' => $reservation->id]);
}
/**
* Build the message.
*
* @return $this
*/
public function build()
{
return $this->view('emails.customer.information')
->subject(__('site/email.client_information.subject').' | '.config('site.company.name'))
->with([
'reservation' => $this->reservation,
'reservationInformationUrl' => $this->reservationInformationUrl,
]);
}
}