Added PDF for pregenerated PDF
This commit is contained in:
@@ -449,11 +449,15 @@ class Renderer {
|
||||
return $mail;
|
||||
}
|
||||
|
||||
protected function sendMail(PHPMailer $mail, string $subject, string $body, string $signature): void {
|
||||
protected function sendMail(PHPMailer $mail, string $subject, string $body, string $signature, $attachments = []): void {
|
||||
$completeBody = $body . $signature . $this->emailLegalInformation();
|
||||
$mail->Subject = $subject;
|
||||
$mail->Body = $completeBody;
|
||||
$mail->AltBody = 'Diese Email benötigt HTML-Ansicht';
|
||||
foreach ($attachments as $fileName => $attachment) {
|
||||
$mail->addStringAttachment($attachment['content'], $fileName, 'base64', $attachment['type']);
|
||||
|
||||
}
|
||||
$mail->send();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user