fix: convert to/cc/bcc array to comma separated emails
This commit is contained in:
parent
127b354ba7
commit
7644958ec7
@ -105,11 +105,14 @@ const onNewEmailChange = (value) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function sendMail() {
|
async function sendMail() {
|
||||||
|
let recipients = newEmailEditor.value.toEmails
|
||||||
|
let cc = newEmailEditor.value.ccEmails
|
||||||
|
let bcc = newEmailEditor.value.bccEmails
|
||||||
await call('frappe.core.doctype.communication.email.make', {
|
await call('frappe.core.doctype.communication.email.make', {
|
||||||
recipients: doc.value.data.email,
|
recipients: recipients.join(','),
|
||||||
attachments: attachments.value.map((x) => x.name),
|
attachments: attachments.value.map((x) => x.name),
|
||||||
cc: '',
|
cc: cc.join(','),
|
||||||
bcc: '',
|
bcc: bcc.join(','),
|
||||||
subject: 'Email from Agent',
|
subject: 'Email from Agent',
|
||||||
content: newEmail.value,
|
content: newEmail.value,
|
||||||
doctype: props.doctype,
|
doctype: props.doctype,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user