Scheduling infrastructure for absolutely everyone.
add zoom as location only if integration enabled, minor readme change (#860)
Anton Podviaznikovd272f32ee3b8
diff --git a/README.md b/README.mdindex 169057a45e4..57fafe053bf 100644--- a/README.md+++ b/README.md@@ -268,7 +268,7 @@ Contributions are what make the open source community such an amazing place to b7. Click "Create".8. Now copy the Client ID and Client Secret to your .env file into the `ZOOM_CLIENT_ID` and `ZOOM_CLIENT_SECRET` fields.9. Set the Redirect URL for OAuth `<Cal.com URL>/api/integrations/zoomvideo/callback` replacing Cal.com URL with the URI at which your application runs.-10. Also add the redirect URL given above as a whitelist URL and enable "Subdomain check". Make sure, it says "saved" below the form.+10. Also add the redirect URL given above as a allow list URL and enable "Subdomain check". Make sure, it says "saved" below the form.11. You don't need to provide basic information about your app. Instead click at "Scopes" and then at "+ Add Scopes". On the left, click the category "Meeting" and check the scope `meeting:write`.12. Click "Done".13. You're good to go. Now you can easily add your Zoom integration in the Cal.com settings.diff --git a/pages/event-types/[type].tsx b/pages/event-types/[type].tsxindex 126ced77430..9ee26de9f4e 100644--- a/pages/event-types/[type].tsx+++ b/pages/event-types/[type].tsx@@ -169,8 +169,8 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {advancedPayload.minimumBookingNotice = asNumberOrUndefined(formData.minimumBookingNotice);// prettier-ignoreadvancedPayload.price =- !requirePayment ? undefined :- formData.price ? Math.round(parseFloat(asStringOrThrow(formData.price)) * 100) :+ !requirePayment ? undefined :+ formData.price ? Math.round(parseFloat(asStringOrThrow(formData.price)) * 100) :/* otherwise */ 0;advancedPayload.currency = currency;}@@ -1277,9 +1277,11 @@ export const getServerSideProps = async (context: GetServerSidePropsContext) =>const locationOptions: OptionTypeBase[] = [{ value: LocationType.InPerson, label: "Link or In-person meeting" },{ value: LocationType.Phone, label: "Phone call" },- { value: LocationType.Zoom, label: "Zoom Video", disabled: true },];+ if (hasIntegration(integrations, "zoom_video")) {+ locationOptions.push({ value: LocationType.Zoom, label: "Zoom Video", disabled: true });+ }const hasPaymentIntegration = hasIntegration(integrations, "stripe_payment");if (hasIntegration(integrations, "google_calendar")) {locationOptions.push({ value: LocationType.GoogleMeet, label: "Google Meet" });