fix: jitsi email does not contain meeting link (#2004)

This commit is contained in:
Krunal Shah 2022-03-03 15:24:19 +05:30 committed by GitHub
parent 15052c8b48
commit c437f15868
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 18 additions and 4 deletions

View file

@ -85,9 +85,6 @@ const BookingPage = (props: BookingPageProps) => {
if (!location) {
return;
}
if (location === "integrations:jitsi") {
return "https://meet.jit.si/cal/" + uuidv4();
}
if (location.includes("integration")) {
return t("web_conferencing_details_to_follow");
}

View file

@ -5,6 +5,7 @@ import { v5 as uuidv5 } from "uuid";
import { FAKE_DAILY_CREDENTIAL } from "@lib/integrations/Daily/DailyVideoApiAdapter";
import { FAKE_HUDDLE_CREDENTIAL } from "@lib/integrations/Huddle01/Huddle01VideoApiAdapter";
import { FAKE_JITSI_CREDENTIAL } from "@lib/integrations/Jitsi/JitsiVideoApiAdapter";
import { createEvent, updateEvent } from "@lib/integrations/calendar/CalendarManager";
import { AdditionInformation, CalendarEvent } from "@lib/integrations/calendar/interfaces/Calendar";
import { LocationType } from "@lib/location";
@ -57,8 +58,14 @@ export const isTandem = (location: string): boolean => {
return location === "integrations:tandem";
};
export const isJitsi = (location: string): boolean => {
return location === "integrations:jitsi";
};
export const isDedicatedIntegration = (location: string): boolean => {
return isZoom(location) || isDaily(location) || isHuddle01(location) || isTandem(location);
return (
isZoom(location) || isDaily(location) || isHuddle01(location) || isTandem(location) || isJitsi(location)
);
};
export const getLocationRequestFromIntegration = (location: string) => {
@ -121,6 +128,7 @@ export default class EventManager {
this.videoCredentials.push(FAKE_DAILY_CREDENTIAL);
}
this.videoCredentials.push(FAKE_HUDDLE_CREDENTIAL);
this.videoCredentials.push(FAKE_JITSI_CREDENTIAL);
}
/**

View file

@ -1,8 +1,17 @@
import { Credential } from "@prisma/client";
import { v4 as uuidv4 } from "uuid";
import { PartialReference } from "@lib/events/EventManager";
import { randomString } from "@lib/random";
import { VideoApiAdapter, VideoCallData } from "@lib/videoClient";
export const FAKE_JITSI_CREDENTIAL: Credential = {
id: +new Date().getTime(),
type: "jitsi_video",
key: { apikey: randomString(12) },
userId: +new Date().getTime(),
};
const JitsiVideoApiAdapter = (): VideoApiAdapter => {
return {
getAvailability: () => {