upd
This commit is contained in:
@@ -42,7 +42,7 @@ function CalendarPage() {
|
||||
async function getScheduledSessions(buildId: string, date: Date) {
|
||||
const result: any[] = await ky
|
||||
.get(
|
||||
`https://crm.stream.graff.tech/api/scheduled_sessions/${buildId}?date=${date.toISOString()}`
|
||||
`https://crm.stream.graff.tech/api/scheduledSessions/${buildId}?date=${date.toISOString()}`
|
||||
)
|
||||
.json();
|
||||
|
||||
@@ -69,7 +69,7 @@ function CalendarPage() {
|
||||
|
||||
try {
|
||||
const result: any = await ky
|
||||
.post(`${import.meta.env.VITE_COORD_URL}/scheduled_sessions`, {
|
||||
.post(`${import.meta.env.VITE_COORD_URL}/scheduledSessions`, {
|
||||
json: {
|
||||
username,
|
||||
name,
|
||||
@@ -128,7 +128,7 @@ function CalendarPage() {
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<div className="min-h-screen flex justify-center items-center p-8 rounded-lg text-white">
|
||||
<div className="flex items-center justify-center min-h-screen p-8 text-white rounded-lg">
|
||||
{step === 1 && (
|
||||
<div className="space-y-8 w-80">
|
||||
<p className="text-4xl font-gilroy">
|
||||
@@ -290,7 +290,7 @@ function CalendarPage() {
|
||||
|
||||
<button
|
||||
type="submit"
|
||||
className="px-4 py-2 bg-gradient w-full rounded"
|
||||
className="w-full px-4 py-2 rounded bg-gradient"
|
||||
>
|
||||
Запланировать
|
||||
</button>
|
||||
@@ -328,7 +328,7 @@ function CalendarPage() {
|
||||
<a
|
||||
href={link}
|
||||
target="_blank"
|
||||
className="inline-block px-4 py-2 bg-gradient w-full rounded text-center"
|
||||
className="inline-block w-full px-4 py-2 text-center rounded bg-gradient"
|
||||
>
|
||||
Подключиться
|
||||
</a>
|
||||
|
||||
@@ -17,7 +17,7 @@ function ScheduledPage() {
|
||||
try {
|
||||
const result: any = await ky
|
||||
.get(
|
||||
`${import.meta.env.VITE_CRM_API_URL}/scheduled_sessions/${
|
||||
`${import.meta.env.VITE_CRM_API_URL}/scheduledSessions/${
|
||||
params.sessionId
|
||||
}`
|
||||
)
|
||||
|
||||
@@ -52,7 +52,7 @@ function SidebarTab2() {
|
||||
.get(
|
||||
`${
|
||||
import.meta.env.VITE_CRM_API_URL
|
||||
}/scheduled_sessions/companies/${companyId}/builds/${buildId}?date=${format(
|
||||
}/scheduledSessions/companies/${companyId}/builds/${buildId}?date=${format(
|
||||
selectedDay,
|
||||
"yyyy-MM-dd"
|
||||
)}`
|
||||
@@ -137,10 +137,10 @@ function SidebarTab2() {
|
||||
}, [schedule]);
|
||||
|
||||
return (
|
||||
<div className="sm:p-8 p-6 flex flex-col justify-between sm:gap-8 gap-6 min-h-full">
|
||||
<div className="flex flex-col justify-between min-h-full gap-6 p-6 sm:p-8 sm:gap-8">
|
||||
<div>
|
||||
<div className="flex items-start justify-between">
|
||||
<p className="text-2xl text-gradient font-semibold font-gilroy w-fit leading-snug">
|
||||
<p className="text-2xl font-semibold leading-snug text-gradient font-gilroy w-fit">
|
||||
<Trans i18nKey={"sidebar.title1"}>Дата и время</Trans>
|
||||
</p>
|
||||
<button
|
||||
@@ -154,7 +154,7 @@ function SidebarTab2() {
|
||||
<div className="mt-2">
|
||||
<div className="grid grid-cols-2 gap-2">
|
||||
<div className="border-b border-[#3D425C] p-4 text-center">
|
||||
<p className="leading-none font-gilroy font-semibold text-sm">
|
||||
<p className="text-sm font-semibold leading-none font-gilroy">
|
||||
{selectedDay &&
|
||||
format(
|
||||
selectedDay,
|
||||
@@ -165,7 +165,7 @@ function SidebarTab2() {
|
||||
</div>
|
||||
|
||||
<div className="border-b border-[#798FFF] p-4 text-center">
|
||||
<p className="leading-none font-gilroy font-semibold text-sm">
|
||||
<p className="text-sm font-semibold leading-none font-gilroy">
|
||||
<Trans i18nKey={"sidebar.time"}>Время</Trans>
|
||||
</p>
|
||||
</div>
|
||||
@@ -179,25 +179,25 @@ function SidebarTab2() {
|
||||
handleSelect={(time) => handleSelectTime(time)}
|
||||
/>
|
||||
) : (
|
||||
<LoaderIcon className="2xl:w-8 2xl:h-8 w-6 h-6 animate-spin" />
|
||||
<LoaderIcon className="w-6 h-6 2xl:w-8 2xl:h-8 animate-spin" />
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className="flex flex-col sm:gap-6 gap-4">
|
||||
<p className="text-center text-xs opacity-50 leading-tight">
|
||||
<div className="flex flex-col gap-4 sm:gap-6">
|
||||
<p className="text-xs leading-tight text-center opacity-50">
|
||||
<Trans i18nKey={"sidebar.notice"}>
|
||||
Запись на демонстрацию работает в ознакомительном режиме и не
|
||||
сохраняет введенные данные
|
||||
</Trans>
|
||||
</p>
|
||||
|
||||
<div className="flex sm:gap-4 gap-2">
|
||||
<div className="flex gap-2 sm:gap-4">
|
||||
<button
|
||||
onClick={() => setCurrentTab(currentTab - 1)}
|
||||
className="px-6 sm:py-4 py-3.5 border border-[#3D425C] rounded-full font-medium group w-full"
|
||||
>
|
||||
<span className="opacity-80 transition-opacity group-hover:opacity-100 sm:text-base text-sm">
|
||||
<span className="text-sm transition-opacity opacity-80 group-hover:opacity-100 sm:text-base">
|
||||
<Trans i18nKey={"sidebar.buttonBack"}>Назад</Trans>
|
||||
</span>
|
||||
</button>
|
||||
|
||||
@@ -38,7 +38,7 @@ function SidebarTab4() {
|
||||
|
||||
try {
|
||||
const result: any = await ky
|
||||
.post(`${import.meta.env.VITE_CRM_API_URL}/scheduled_sessions`, {
|
||||
.post(`${import.meta.env.VITE_CRM_API_URL}/scheduledSessions`, {
|
||||
json: {
|
||||
buildId,
|
||||
startAt,
|
||||
@@ -63,10 +63,10 @@ function SidebarTab4() {
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="sm:p-8 p-6 flex flex-col justify-between sm:gap-8 gap-6 min-h-full">
|
||||
<div className="flex flex-col justify-between min-h-full gap-6 p-6 sm:p-8 sm:gap-8">
|
||||
<div>
|
||||
<div className="flex items-start justify-between">
|
||||
<p className="text-2xl text-gradient font-semibold font-gilroy w-fit leading-snug">
|
||||
<p className="text-2xl font-semibold leading-snug text-gradient font-gilroy w-fit">
|
||||
<Trans i18nKey={"sidebar.title3"}>Проверка заявки</Trans>
|
||||
</p>
|
||||
<button
|
||||
@@ -77,13 +77,13 @@ function SidebarTab4() {
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div className="sm:mt-6 mt-4">
|
||||
<div className="mt-4 sm:mt-6">
|
||||
<div className="sm:mt-6 mt-4 sm:p-6 p-4 flex flex-col gap-6 font-semibold font-gilroy border border-[#3D425C] ">
|
||||
<p className="leading-tight">
|
||||
<Trans i18nKey={"sidebar.sessionDetails"}>Детали сеанса</Trans>
|
||||
</p>
|
||||
<div className="flex flex-col gap-2">
|
||||
<div className="flex justify-between sm:text-base text-sm">
|
||||
<div className="flex justify-between text-sm sm:text-base">
|
||||
<p className="opacity-50">
|
||||
<Trans i18nKey={"sidebar.date"}>Дата</Trans>
|
||||
</p>
|
||||
@@ -96,7 +96,7 @@ function SidebarTab4() {
|
||||
)}
|
||||
</p>
|
||||
</div>
|
||||
<div className="flex justify-between sm:text-base text-sm">
|
||||
<div className="flex justify-between text-sm sm:text-base">
|
||||
<p className="opacity-50">
|
||||
<Trans i18nKey={"sidebar.time"}>Время</Trans>
|
||||
</p>
|
||||
@@ -112,19 +112,19 @@ function SidebarTab4() {
|
||||
</Trans>
|
||||
</p>
|
||||
<div className="flex flex-col gap-2">
|
||||
<div className="flex justify-between sm:text-base text-sm">
|
||||
<div className="flex justify-between text-sm sm:text-base">
|
||||
<p className="opacity-50">
|
||||
<Trans i18nKey={"sidebar.name"}>Имя</Trans>
|
||||
</p>
|
||||
<p>{name}</p>
|
||||
</div>
|
||||
<div className="flex justify-between sm:text-base text-sm">
|
||||
<div className="flex justify-between text-sm sm:text-base">
|
||||
<p className="opacity-50">
|
||||
<Trans i18nKey={"sidebar.phone"}>Телефон</Trans>
|
||||
</p>
|
||||
<p>{phone}</p>
|
||||
</div>
|
||||
<div className="flex justify-between sm:text-base text-sm">
|
||||
<div className="flex justify-between text-sm sm:text-base">
|
||||
<p className="opacity-50">Email</p>
|
||||
<p>{email}</p>
|
||||
</div>
|
||||
@@ -152,20 +152,20 @@ function SidebarTab4() {
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className="flex flex-col sm:gap-6 gap-4">
|
||||
<p className="text-center text-xs opacity-50 leading-tight">
|
||||
<div className="flex flex-col gap-4 sm:gap-6">
|
||||
<p className="text-xs leading-tight text-center opacity-50">
|
||||
<Trans i18nKey={"sidebar.notice"}>
|
||||
Запись на демонстрацию работает в ознакомительном режиме и не
|
||||
сохраняет введенные данные
|
||||
</Trans>
|
||||
</p>
|
||||
|
||||
<div className="flex sm:gap-4 gap-2">
|
||||
<div className="flex gap-2 sm:gap-4">
|
||||
<button
|
||||
onClick={() => setCurrentTab(currentTab - 1)}
|
||||
className="px-6 py-4 border border-[#3D425C] rounded-full sm:text-base text-sm font-medium group w-fit"
|
||||
>
|
||||
<span className="opacity-80 transition-opacity group-hover:opacity-100">
|
||||
<span className="transition-opacity opacity-80 group-hover:opacity-100">
|
||||
<Trans i18nKey={"sidebar.buttonBack"}>Назад</Trans>
|
||||
</span>
|
||||
</button>
|
||||
@@ -173,15 +173,15 @@ function SidebarTab4() {
|
||||
<button
|
||||
disabled={isLoading}
|
||||
onClick={() => void handleClickSignUp()}
|
||||
className="px-6 py-3 bg-gradient rounded-full sm:text-base text-sm font-medium flex items-center justify-between w-full disabled:opacity-75"
|
||||
className="flex items-center justify-between w-full px-6 py-3 text-sm font-medium rounded-full bg-gradient sm:text-base disabled:opacity-75"
|
||||
>
|
||||
<span>
|
||||
<Trans i18nKey={"sidebar.buttonSignUp"}>Записаться</Trans>
|
||||
</span>
|
||||
{!isLoading ? (
|
||||
<ArrowRightIcon className="sm:w-8 sm:h-8 w-6 h-6" />
|
||||
<ArrowRightIcon className="w-6 h-6 sm:w-8 sm:h-8" />
|
||||
) : (
|
||||
<LoaderIcon className="sm:w-8 sm:h-8 w-6 h-6 animate-spin" />
|
||||
<LoaderIcon className="w-6 h-6 sm:w-8 sm:h-8 animate-spin" />
|
||||
)}
|
||||
</button>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user