fix: hook up cc and bcc fields to mail sender

This commit is contained in:
Ahmed Bouhuolia
2024-11-02 19:33:29 +02:00
parent bd5e33855a
commit 51905825fd
5 changed files with 23 additions and 3 deletions

View File

@@ -126,7 +126,6 @@ export class SendSaleEstimateMail {
mailOptions: SaleEstimateMailOptions
): Promise<SaleEstimateMailOptions> => {
const formatterArgs = await this.formatterArgs(tenantId, saleEstimateId);
const formattedOptions =
await this.contactMailNotification.formatMailOptions(
tenantId,
@@ -166,6 +165,8 @@ export class SendSaleEstimateMail {
const mail = new Mail()
.setSubject(formattedOptions.subject)
.setTo(formattedOptions.to)
.setCC(formattedOptions.cc)
.setBCC(formattedOptions.bcc)
.setContent(formattedOptions.message);
// Attaches the estimate pdf to the mail.