-
- {!forms?.length ? (
-
}
- />
- ) : null}
- {forms?.length ? (
-
-
- {forms.map((form, index) => {
- if (!form) {
- return null;
- }
+ }
+ subtitle={t("routing_forms_description")}>
+ }
+ buttons={
+
+
+
+
+
+
+ }>
+
+
+
+ {!forms?.length ? (
+
}
+ />
+ ) : null}
+ {forms?.length ? (
+
+
+ {forms.map((form, index) => {
+ if (!form) {
+ return null;
+ }
- const description = form.description || "";
- const disabled = form.disabled;
- form.routes = form.routes || [];
- const fields = form.fields || [];
- return (
-
-
-
-
+ const description = form.description || "";
+ const disabled = form.disabled;
+ form.routes = form.routes || [];
+ const fields = form.fields || [];
+ return (
+
+
+
+
+
+
-
-
-
-
- {t("edit")}
-
-
- {t("download_responses")}
-
-
- {t("embed")}
-
-
- {t("duplicate")}
-
- {typeformApp?.isInstalled ? (
+
- {t("Copy Typeform Redirect Url")}
+ className="!flex"
+ StartIcon={Icon.FiEdit}>
+ {t("edit")}
- ) : null}
-
-
- {t("delete")}
-
-
-
- >
- }>
-
-
- {fields.length} {fields.length === 1 ? "field" : "fields"}
-
-
- {form.routes.length} {form.routes.length === 1 ? "route" : "routes"}
-
-
- {form._count.responses} {form._count.responses === 1 ? "response" : "responses"}
-
-
-
- );
- })}
-
-
- ) : null}
+
+ {t("download_responses")}
+
+
+ {t("embed")}
+
+
+ {t("duplicate")}
+
+ {typeformApp?.isInstalled ? (
+
+ {t("Copy Typeform Redirect Url")}
+
+ ) : null}
+
+
+ {t("delete")}
+
+
+
+ >
+ }>
+
+
+ {fields.length} {fields.length === 1 ? "field" : "fields"}
+
+
+ {form.routes.length} {form.routes.length === 1 ? "route" : "routes"}
+
+
+ {form._count.responses} {form._count.responses === 1 ? "response" : "responses"}
+
+
+
+ );
+ })}
+
+
+ ) : null}
+
-
-
+
+
);
}
diff --git a/packages/app-store/ee/routing-forms/playwright/tests/basic.e2e.ts b/packages/app-store/ee/routing-forms/playwright/tests/basic.e2e.ts
index 57ed3be2c8..e413277403 100644
--- a/packages/app-store/ee/routing-forms/playwright/tests/basic.e2e.ts
+++ b/packages/app-store/ee/routing-forms/playwright/tests/basic.e2e.ts
@@ -118,7 +118,12 @@ test.describe("Routing Forms", () => {
// TODO: How to install the app just once?
test.beforeEach(async ({ page, users }) => {
- const user = await users.create({ username: "routing-forms" });
+ const user = await users.create(
+ { username: "routing-forms" },
+ {
+ hasTeam: true,
+ }
+ );
await user.login();
// Install app
await page.goto(`/apps/routing-forms`);
@@ -148,7 +153,10 @@ test.describe("Routing Forms", () => {
users: Fixtures["users"];
page: Page;
}) {
- const user = await users.create({ username: "routing-forms" }, { seedRoutingForms: true });
+ const user = await users.create(
+ { username: "routing-forms" },
+ { seedRoutingForms: true, hasTeam: true }
+ );
await user.login();
// Install app
await page.goto(`/apps/routing-forms`);
diff --git a/packages/app-store/typeform/playwright/tests/basic.e2e.ts b/packages/app-store/typeform/playwright/tests/basic.e2e.ts
index d8d74147e0..ce52acb620 100644
--- a/packages/app-store/typeform/playwright/tests/basic.e2e.ts
+++ b/packages/app-store/typeform/playwright/tests/basic.e2e.ts
@@ -8,7 +8,12 @@ import { CAL_URL } from "@calcom/lib/constants";
import { Fixtures, test } from "@calcom/web/playwright/lib/fixtures";
const installApps = async (page: Page, users: Fixtures["users"]) => {
- const user = await users.create({ username: "routing-forms" });
+ const user = await users.create(
+ { username: "routing-forms" },
+ {
+ hasTeam: true,
+ }
+ );
await user.login();
await page.goto(`/apps/routing-forms`);
await page.click('[data-testid="install-app-button"]');
diff --git a/packages/features/ee/teams/components/TeamsListing.tsx b/packages/features/ee/teams/components/TeamsListing.tsx
index 57fd3356b4..43fa44cadc 100644
--- a/packages/features/ee/teams/components/TeamsListing.tsx
+++ b/packages/features/ee/teams/components/TeamsListing.tsx
@@ -3,10 +3,10 @@ import { useState } from "react";
import { WEBAPP_URL } from "@calcom/lib/constants";
import { APP_NAME } from "@calcom/lib/constants";
import { useLocale } from "@calcom/lib/hooks/useLocale";
-import isCalcom from "@calcom/lib/isCalcom";
import { trpc } from "@calcom/trpc/react";
-import { Alert, Button, ButtonGroup, EmptyScreen, Icon } from "@calcom/ui";
+import { Alert, Button, ButtonGroup, Icon } from "@calcom/ui";
+import { UpgradeTip } from "../../../tips";
import SkeletonLoaderTeamList from "./SkeletonloaderTeamList";
import TeamList from "./TeamList";
@@ -21,36 +21,35 @@ export function TeamsListing() {
});
const teams = data?.filter((m) => m.accepted) || [];
- const invites = data?.filter((m) => !m.accepted) || [];
const features = [
{
- icon:
,
+ icon:
,
title: t("collective_scheduling"),
description: t("make_it_easy_to_book"),
},
{
- icon:
,
+ icon:
,
title: t("round_robin"),
description: t("find_the_best_person"),
},
{
- icon:
,
+ icon:
,
title: t("fixed_round_robin"),
description: t("add_one_fixed_attendee"),
},
{
- icon:
,
+ icon:
,
title: t("sms_attendee_action"),
description: t("make_it_easy_to_book"),
},
{
- icon:
,
+ icon:
,
title: "Cal Video" + " " + t("recordings_title"),
description: t("upgrade_to_access_recordings_description"),
},
{
- icon:
,
+ icon:
,
title: t("disable_cal_branding", { appName: APP_NAME }),
description: t("disable_cal_branding_description", { appName: APP_NAME }),
},
@@ -59,66 +58,26 @@ export function TeamsListing() {
return (
<>
{!!errorMessage &&
}
- {invites.length > 0 && (
-
-
{t("open_invitations")}
-
-
- )}
- {isLoading &&
}
- {!teams.length && !isLoading && (
- <>
- {!isCalcom ? (
-
-
-
-
{t("calcom_is_better_with_team")}
-
{t("add_your_team_members")}
-
-
-
-
-
-
-
-
-
- {features.map((feature) => (
-
- {feature.icon}
-
{feature.title}
-
{feature.description}
-
- ))}
-
-
- ) : (
-
- {t("create_team")}
-
- }
- />
- )}
- >
- )}
- {teams.length > 0 && }
+ }
+ buttons={
+
+
+
+
+
+
+ }>
+
+
>
);
}
diff --git a/packages/features/ee/video/ViewRecordingsDialog.tsx b/packages/features/ee/video/ViewRecordingsDialog.tsx
index 0b46197c43..96343263af 100644
--- a/packages/features/ee/video/ViewRecordingsDialog.tsx
+++ b/packages/features/ee/video/ViewRecordingsDialog.tsx
@@ -1,8 +1,8 @@
-import { useSession } from "next-auth/react";
import { useState } from "react";
import dayjs from "@calcom/dayjs";
import LicenseRequired from "@calcom/features/ee/common/components/v2/LicenseRequired";
+import useHasTeamPlan from "@calcom/lib/hooks/useHasTeamPlan";
import { useLocale } from "@calcom/lib/hooks/useLocale";
import { RecordingItemSchema } from "@calcom/prisma/zod-utils";
import { RouterOutputs, trpc } from "@calcom/trpc/react";
@@ -18,7 +18,6 @@ import {
import { Button, showToast, Icon } from "@calcom/ui";
import RecordingListSkeleton from "./components/RecordingListSkeleton";
-import UpgradeRecordingBanner from "./components/UpgradeRecordingBanner";
type BookingItem = RouterOutputs["viewer"]["bookings"]["get"]["bookings"][number];
@@ -65,7 +64,9 @@ export const ViewRecordingsDialog = (props: IViewRecordingsDialog) => {
const { t, i18n } = useLocale();
const { isOpenDialog, setIsOpenDialog, booking, timeFormat } = props;
const [downloadingRecordingId, setRecordingId] = useState(null);
- const { data: dataHasTeamPlan, isLoading: isLoadingHasTeamPlan } = trpc.viewer.teams.hasTeamPlan.useQuery();
+
+ const { hasTeamPlan, isLoading: isTeamPlanStatusLoading } = useHasTeamPlan();
+
const roomName =
booking?.references?.find((reference: PartialReference) => reference.type === "daily_video")?.meetingId ??
undefined;
@@ -109,7 +110,7 @@ export const ViewRecordingsDialog = (props: IViewRecordingsDialog) => {
<>
- {(isLoading || isLoadingHasTeamPlan) && }
+ {(isLoading || isTeamPlanStatusLoading) && }
{recordings && "data" in recordings && recordings?.data?.length > 0 && (
{recordings.data.map((recording: RecordingItemSchema, index: number) => {
@@ -125,7 +126,7 @@ export const ViewRecordingsDialog = (props: IViewRecordingsDialog) => {
{convertSecondsToMs(recording.duration)}
- {dataHasTeamPlan?.hasTeamPlan ? (
+ {hasTeamPlan ? (