Show eventDescription on email (#2371)
* Show eventDescription on email * Fixing Inheritance * Fixing Duplicate getLocation * Type fixes Co-authored-by: zomars <[email protected]>
This commit is contained in:
1 parent
5e7d34b9c4
commit
96f6294542
17 files changed
+67
-13
No files matched your search
@@ -104,7 +104,7 @@ export const createEvent = async (credential: Credential, calEvent: CalendarEven
|
||||
|
||||
// Check if the disabledNotes flag is set to true
|
||||
if (calEvent.hideCalendarNotes) {
|
||||
calEvent.description = "Notes have been hidden by the organiser"; // TODO: i18n this string?
|
||||
calEvent.additionalNotes = "Notes have been hidden by the organiser"; // TODO: i18n this string?
|
||||
}
|
||||
|
||||
const creationResult = calendar
|
||||
|
||||
@@ -48,10 +48,15 @@ ${organizer + attendees}
|
||||
export const getAdditionalNotes = (calEvent: CalendarEvent) => {
|
||||
return `
|
||||
${calEvent.organizer.language.translate("additional_notes")}:
|
||||
${calEvent.description}
|
||||
${calEvent.additionalNotes}
|
||||
`;
|
||||
};
|
||||
|
||||
export const getDescription = (calEvent: CalendarEvent) => {
|
||||
return `\n${calEvent.attendees[0].language.translate("description")}
|
||||
${calEvent.description}
|
||||
`;
|
||||
};
|
||||
export const getLocation = (calEvent: CalendarEvent) => {
|
||||
let providerName = "";
|
||||
|
||||
@@ -97,6 +102,7 @@ ${getWhen(calEvent)}
|
||||
${getWho(calEvent)}
|
||||
${calEvent.organizer.language.translate("where")}:
|
||||
${getLocation(calEvent)}
|
||||
${getDescription(calEvent)}
|
||||
${getAdditionalNotes(calEvent)}
|
||||
`.trim();
|
||||
}
|
||||
@@ -107,6 +113,7 @@ ${getWhen(calEvent)}
|
||||
${getWho(calEvent)}
|
||||
${calEvent.organizer.language.translate("where")}:
|
||||
${getLocation(calEvent)}
|
||||
${getDescription(calEvent)}
|
||||
${getAdditionalNotes(calEvent)}
|
||||
${getManageLink(calEvent)}
|
||||
`.trim();
|
||||
|
||||
Vendored
+1
@@ -75,6 +75,7 @@ export interface CalendarEvent {
|
||||
title: string;
|
||||
startTime: string;
|
||||
endTime: string;
|
||||
additionalNotes?: string | null;
|
||||
description?: string | null;
|
||||
team?: {
|
||||
name: string;
|
||||
|
||||
Reference in new issue
Block a user