fix: corretto invio da mail (scrittura diretta nel db). feat: aggiunta gestione di gruppi interni per l'invio delle mail

This commit is contained in:
Gabriele Cimaschi
2026-07-09 22:36:46 +02:00
parent 725bdaeae4
commit 191f9a407b
11 changed files with 833 additions and 313 deletions
+3 -1
View File
@@ -29,7 +29,7 @@ function getTransporter() {
* Invia una email tramite SMTP (nodemailer).
* Stessa interfaccia di graphMailer.sendMail.
*/
async function sendMail({ to, cc = [], bcc = [], subject, bodyHtml, attachments = [], inlineImages = [] }) {
async function sendMail({ to, cc = [], bcc = [], subject, bodyHtml, attachments = [], inlineImages = [], inReplyTo, references }) {
const transporter = getTransporter();
const mailOptions = {
@@ -39,6 +39,8 @@ async function sendMail({ to, cc = [], bcc = [], subject, bodyHtml, attachments
bcc: bcc.length ? bcc.join(', ') : undefined,
subject,
html: bodyHtml,
inReplyTo,
references,
attachments: [
...attachments.map(a => ({
filename: a.filename,