mirror of
https://github.com/RaspbianFrance/raspisms.git
synced 2025-04-20 16:37:48 +02:00
add mms files to mail transfert
This commit is contained in:
parent
d29424ff0c
commit
e06079e6af
5 changed files with 17 additions and 5 deletions
|
@ -291,12 +291,20 @@ namespace controllers\internals;
|
|||
}
|
||||
|
||||
$mailer = new Mailer();
|
||||
|
||||
$attachments = [];
|
||||
|
||||
foreach ($received['medias'] ?? [] as $media)
|
||||
{
|
||||
$attachments[] = PWD_DATA_PUBLIC . '/' . $media['path'];
|
||||
}
|
||||
|
||||
return $mailer->enqueue($user['email'], EMAIL_TRANSFER_SMS, [
|
||||
'at' => $received['at'],
|
||||
'origin' => $received['origin'],
|
||||
'destination' => $phone['name'],
|
||||
'text' => $received['text'],
|
||||
]);
|
||||
'mms' => $received['mms'] ?? false,
|
||||
], $attachments);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue