41 lines
1.0 KiB
PHP
41 lines
1.0 KiB
PHP
<?php
|
|
|
|
namespace App\Mail;
|
|
|
|
use App\Models\Communication;
|
|
use App\Models\CommunicationReply;
|
|
use Illuminate\Bus\Queueable;
|
|
use Illuminate\Mail\Mailable;
|
|
use Illuminate\Mail\Mailables\Address;
|
|
use Illuminate\Mail\Mailables\Content;
|
|
use Illuminate\Mail\Mailables\Envelope;
|
|
use Illuminate\Queue\SerializesModels;
|
|
|
|
class ContactInquiryReplyMail extends Mailable
|
|
{
|
|
use Queueable, SerializesModels;
|
|
|
|
public function __construct(
|
|
public Communication $communication,
|
|
public CommunicationReply $reply
|
|
) {}
|
|
|
|
public function envelope(): Envelope
|
|
{
|
|
return new Envelope(
|
|
from: new Address('info@jouwdriedee.nl', 'Jouwdriedee.nl Klantenservice'),
|
|
replyTo: [
|
|
new Address('info@jouwdriedee.nl', 'Jouwdriedee.nl Klantenservice'),
|
|
],
|
|
subject: 'Reactie op jouw vraag: '.$this->communication->subject.' - Jouwdriedee.nl',
|
|
);
|
|
}
|
|
|
|
public function content(): Content
|
|
{
|
|
return new Content(
|
|
view: 'emails.contact-inquiry-reply',
|
|
);
|
|
}
|
|
}
|