import EventAttendeeMail from "./EventAttendeeMail";
import { getFormattedMeetingId, getIntegrationName } from "./helpers";
export default class VideoEventAttendeeMail extends EventAttendeeMail {
/**
* Adds the video call information to the mail body.
*
* @protected
*/
protected getAdditionalBody(): string {
if (!this.calEvent.videoCallData) {
return "";
}
const meetingPassword = this.calEvent.videoCallData.password;
const meetingId = getFormattedMeetingId(this.calEvent.videoCallData);
if (meetingId && meetingPassword) {
return `
${this.calEvent.language("video_call_provider")}: ${getIntegrationName(
this.calEvent.videoCallData
)}
${this.calEvent.language("meeting_id")}: ${getFormattedMeetingId(
this.calEvent.videoCallData
)}
${this.calEvent.language("meeting_password")}: ${
this.calEvent.videoCallData.password
}
${this.calEvent.language("meeting_url")}: ${this.calEvent.videoCallData.url}
`;
}
return `
${this.calEvent.language("video_call_provider")}: ${getIntegrationName(
this.calEvent.videoCallData
)}
${this.calEvent.language("meeting_url")}: ${this.calEvent.videoCallData.url}
`;
}
}