Upload image with form widget and send by email
Hello,
I have a blueprint dashboard with a form widget. There is an upload file field and I want to trigger an analysis with submit button that send this file by email.
I have this:
const attachment = scope.find(x=> x.variable ===
'attachment')
await email_service.send({
to: 'email',
subject: 'Title',
attachment: {
filename: attachment?.metadata?.file?.path,
archive: attachment?.metadata?.file?.path,
},
message: 'Message',
}
).then(context.log).catch(context.log);
The problem is that the attached file arrives empty to the receiver. Any idea?