Skip to content
Snippets Groups Projects
Commit da404a28 authored by Sebastian Mihalache's avatar Sebastian Mihalache
Browse files

feat(component-invite): send thank you email to reviewer

parent 49356cd1
No related branches found
No related tags found
1 merge request!10Sprint #12
......@@ -80,6 +80,17 @@ const setupReviewerDecisionEmailData = async ({
timestamp,
},
})
await mailService.sendNotificationEmail({
toEmail: user.email,
user,
emailType: 'reviewer-thank-you',
meta: {
collection: { customId: collection.customId, id: collection.id },
fragment: { id, title, authorName },
handlingEditorName: collection.handlingEditor.name,
baseUrl,
},
})
}
const setupReviewerUnassignEmail = async ({
......
......@@ -345,6 +345,24 @@ module.exports = {
replacements.signatureName
}`
break
case 'reviewer-thank-you':
subject = `${meta.collection.customId}: Manuscript Review`
replacements.previewText = 'Hindawi says thank you'
replacements.intro = `Dear Dr. ${user.firstName} ${user.lastName}`
replacements.paragraph = `Thank you for agreeing to review the manuscript titled "${
meta.fragment.title
}" by ${meta.fragment.authorName}.`
replacements.beforeAnchor =
'You can view the full PDF file of the manuscript and post your review report using the following URL:'
replacements.afterAnchor = ''
replacements.signatureName = meta.handlingEditorName
textBody = `${replacements.intro} ${replacements.paragraph} ${
replacements.beforeAnchor
} ${replacements.detailsUrl} ${replacements.afterAnchor} ${
replacements.signatureName
}`
break
default:
subject = 'Hindawi Notification!'
break
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment