Added initial order confirmation e-mail template #48

This commit is contained in:
2025-10-29 12:07:30 +01:00
parent 42127077aa
commit f76d55f4f0
4 changed files with 468 additions and 15 deletions
+54
View File
@@ -0,0 +1,54 @@
<?php
namespace App\Mail;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Mail\Mailable;
use Illuminate\Mail\Mailables\Content;
use Illuminate\Mail\Mailables\Address;
use Illuminate\Mail\Mailables\Envelope;
use Illuminate\Queue\SerializesModels;
class OrderConfirmation extends Mailable
{
use Queueable, SerializesModels;
/**
* Create a new message instance.
*/
public function __construct(public array $offer) {}
/**
* Get the message envelope.
*/
public function envelope(): Envelope
{
return new Envelope(
// TODO: get from settings
from: new Address('buchhaltung@tooloop.de', 'Tooloop Multimedia'),
bcc: [new Address('daniel.stock@tooloop.de', '<Daniel Stock')],
subject: 'Auftragsbestätigung',
);
}
/**
* Get the message content definition.
*/
public function content(): Content
{
return new Content(
view: 'mail.offers.confirmation',
);
}
/**
* Get the attachments for the message.
*
* @return array<int, \Illuminate\Mail\Mailables\Attachment>
*/
public function attachments(): array
{
return [];
}
}