* Fix #4457 (remove event type action buttons) * Configured backPath Co-authored-by: Joe Au-Yeung <65426560+joeauyeung@users.noreply.github.com> Co-authored-by: Bailey Pumfleet <pumfleet@hey.com>pull/4348/head^2
parent
e29d9cd545
commit
2281c7cf9f
|
@ -154,6 +154,7 @@ function EventTypeSingleLayout({
|
|||
|
||||
return (
|
||||
<Shell
|
||||
backPath="/event-types"
|
||||
title={t("event_type_title", { eventTypeTitle: eventType.title })}
|
||||
heading={eventType.title}
|
||||
subtitle={eventType.description || ""}
|
||||
|
|
|
@ -17,7 +17,7 @@ import prisma from "@calcom/prisma";
|
|||
import { trpc } from "@calcom/trpc/react";
|
||||
import type { RecurringEvent } from "@calcom/types/Calendar";
|
||||
import { Form } from "@calcom/ui/form/fields";
|
||||
import { Button, showToast } from "@calcom/ui/v2";
|
||||
import { showToast } from "@calcom/ui/v2";
|
||||
|
||||
import { asStringOrThrow } from "@lib/asStringOrNull";
|
||||
import { getSession } from "@lib/auth";
|
||||
|
@ -37,8 +37,6 @@ import EventWorkflowsTab from "@components/v2/eventtype/EventWorkfowsTab";
|
|||
|
||||
import { getTranslation } from "@server/lib/i18n";
|
||||
|
||||
const TABS_WITHOUT_ACTION_BUTTONS = ["workflows", "availability"];
|
||||
|
||||
export type FormValues = {
|
||||
title: string;
|
||||
eventTitle: string;
|
||||
|
@ -245,16 +243,6 @@ const EventTypePage = (props: inferSSRProps<typeof getServerSideProps>) => {
|
|||
<div ref={animationParentRef} className="space-y-6">
|
||||
{tabMap[tabName]}
|
||||
</div>
|
||||
{!TABS_WITHOUT_ACTION_BUTTONS.includes(tabName) && (
|
||||
<div className="mt-4 flex justify-end space-x-2 rtl:space-x-reverse">
|
||||
<Button href="/event-types" color="secondary" tabIndex={-1}>
|
||||
{t("cancel")}
|
||||
</Button>
|
||||
<Button type="submit" data-testid="update-eventtype" disabled={updateMutation.isLoading}>
|
||||
{t("update")}
|
||||
</Button>
|
||||
</div>
|
||||
)}
|
||||
</Form>
|
||||
</EventTypeSingleLayout>
|
||||
);
|
||||
|
|
Loading…
Reference in New Issue