Only include app status to email

refactor/generate-ics-event
Joe Au-Yeung 2023-10-30 13:18:54 -04:00
parent 49706b0bd4
commit 1c79b5532f
5 changed files with 10 additions and 6 deletions

View File

@ -114,7 +114,7 @@ ${this.t(
)}
${this.t(subtitle)}
${getRichDescription(this.calEvent, this.t)}
${getRichDescription(this.calEvent, this.t, true)}
`.trim();
}

View File

@ -53,7 +53,7 @@ ${this.t(
)}
${this.t(subtitle)}
${extraInfo}
${getRichDescription(this.calEvent)}
${getRichDescription(this.calEvent, this.t, true)}
${callToAction}
`.trim();
}

View File

@ -88,7 +88,7 @@ export default class OrganizerRequestedToRescheduleEmail extends OrganizerSchedu
${this.t(title)}
${this.t(subtitle)}
${extraInfo}
${getRichDescription(this.calEvent)}
${getRichDescription(this.calEvent, this.t, true)}
${callToAction}
`.trim();
}

View File

@ -105,7 +105,7 @@ ${this.t(
)}
${this.t(subtitle)}
${extraInfo}
${getRichDescription(this.calEvent)}
${getRichDescription(this.calEvent, this.t, true)}
${callToAction}
`.trim();
}

View File

@ -176,7 +176,11 @@ export const getRescheduleLink = (calEvent: CalendarEvent): string => {
return `${calEvent.bookerUrl ?? WEBAPP_URL}/reschedule/${seatUid ? seatUid : Uid}`;
};
export const getRichDescription = (calEvent: CalendarEvent, t_?: TFunction /*, attendee?: Person*/) => {
export const getRichDescription = (
calEvent: CalendarEvent,
t_?: TFunction /*, attendee?: Person*/,
includeAppStatus = false
) => {
const t = t_ ?? calEvent.organizer.language.translate;
return `
@ -189,7 +193,7 @@ ${getLocation(calEvent)}
${getDescription(calEvent, t)}
${getAdditionalNotes(calEvent, t)}
${getUserFieldsResponses(calEvent)}
${getAppsStatus(calEvent, t)}
${includeAppStatus ? getAppsStatus(calEvent, t) : ""}
${
// TODO: Only the original attendee can make changes to the event
// Guests cannot