From 80499e68d59cb2e72ed1e93c97033c1bae7b72cc Mon Sep 17 00:00:00 2001 From: Edouard Richard Date: Wed, 20 Mar 2024 12:36:27 +0100 Subject: [PATCH] feat(create-one.js): add case for MOVE_CARD action type in sendEmailNotification function to support email notifications when a card is moved --- server/api/helpers/notifications/create-one.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/server/api/helpers/notifications/create-one.js b/server/api/helpers/notifications/create-one.js index 8603a08..d9242c8 100644 --- a/server/api/helpers/notifications/create-one.js +++ b/server/api/helpers/notifications/create-one.js @@ -46,6 +46,16 @@ async function sendEmailNotification({ notification, action }) { `

${action.data.text}

`, }; break; + case Action.Types.MOVE_CARD: + email = { + subject: `${actionUser.name} moved the card ${actionCard.name} from ${action.data.fromList.name} to ${action.data.toList.name} on ${actionBoard.name}`, + html: + `

${actionUser.name} moved the card ` + + `${actionCard.name} ` + + `from ${action.data.fromList.name} to ${action.data.toList.name} ` + + `on ${actionBoard.name}

`, + }; + break; default: break;