feat: email workflow templates translation (#20674)

* Add translations in respective files

* implement multilingual support for email templates

* fix: indentation in common.js & typos in common.js and update.handler.ts
This commit is contained in:
Giridhar authored and GitHub committed 2025-04-15 23:56:34 +05:30
1 parent 417acdaacb
commit 381c462660
52 files changed
+630 -76

No files matched your search

@@ -7,6 +7,7 @@ import compareReminderBodyToTemplate from "@calcom/features/ee/workflows/lib/com
import { lockUser, LockReason } from "@calcom/lib/autoLock";
import { WEBAPP_URL } from "@calcom/lib/constants";
import logger from "@calcom/lib/logger";
import { getTranslation } from "@calcom/lib/server/i18n";
import { getTimeFormatStringFromUserTimeFormat } from "@calcom/lib/timeFormat";
import prisma from "@calcom/prisma";
import { scheduleWorkflowNotifications } from "@calcom/trpc/server/routers/viewer/workflows/util";
@@ -67,6 +68,7 @@ export async function scanWorkflowBody(payload: string) {
const defaultTemplate = getTemplateBodyForAction({
action: workflowStep.action,
locale: workflowStep.workflow.user?.locale ?? "en",
t: await getTranslation(workflowStep.workflow.user?.locale ?? "en", "common"),
template: workflowStep.template,
timeFormat,
});