diff --git a/packages/web/src/components/ModalPopup/ModalChatPayment.tsx b/packages/web/src/components/ModalPopup/ModalChatPayment.tsx index d19b55b1..cfcafc6f 100644 --- a/packages/web/src/components/ModalPopup/ModalChatPayment.tsx +++ b/packages/web/src/components/ModalPopup/ModalChatPayment.tsx @@ -1,7 +1,6 @@ import { useCallback, useEffect, useMemo, useRef, useState } from "react"; import useAccountFromChats from "@/hooks/chat/useAccountFromChats"; -import { useEvent2024FallQuestComplete } from "@/hooks/event/useEvent2024FallQuestComplete"; import { useValueRecoilState } from "@/hooks/useFetchRecoilState"; import { useAxios } from "@/hooks/useTaxiAPI"; @@ -50,9 +49,6 @@ const ModalChatPayment = ({ [userOid, roomInfo] ); const onCopy = useCallback(() => setIsCopied(true), [setIsCopied]); - //#region event2024Fall - const event2024FallQuestComplete = useEvent2024FallQuestComplete(); - //#endregion useEffect(() => { if (isCopied) { @@ -69,9 +65,6 @@ const ModalChatPayment = ({ method: "post", data: { roomId: roomInfo._id }, onSuccess: () => { - //#region event2024Fall - event2024FallQuestComplete("farePayment"); - //#endregion modalProps.onChangeIsOpen?.(false); onRecall?.(); }, diff --git a/packages/web/src/components/ModalPopup/ModalChatSaveAccount.tsx b/packages/web/src/components/ModalPopup/ModalChatSaveAccount.tsx index e5ce6b20..5aec2dc6 100644 --- a/packages/web/src/components/ModalPopup/ModalChatSaveAccount.tsx +++ b/packages/web/src/components/ModalPopup/ModalChatSaveAccount.tsx @@ -1,6 +1,5 @@ import { useCallback, useEffect, useState } from "react"; -import { useEvent2024FallQuestComplete } from "@/hooks/event/useEvent2024FallQuestComplete"; import { useFetchRecoilState, useValueRecoilState, @@ -32,9 +31,6 @@ const ModalChatSaveAcount = ({ const { account: accountOrigin } = useValueRecoilState("loginInfo") || {}; const [account, setAccount] = useState(accountDefault || ""); const fetchLoginInfo = useFetchRecoilState("loginInfo"); - //#region event2024Fall - const event2024FallQuestComplete = useEvent2024FallQuestComplete(); - //#endregion useEffect(() => setAccount(accountDefault || ""), [accountDefault]); @@ -45,9 +41,6 @@ const ModalChatSaveAcount = ({ method: "post", data: { account }, onSuccess: () => { - //#region event2024Fall - event2024FallQuestComplete("accountChanging"); - //#endregion fetchLoginInfo(); }, onError: () => setAlert("계좌번호 저장을 실패하였습니다."), diff --git a/packages/web/src/components/ModalPopup/ModalChatSettlement.tsx b/packages/web/src/components/ModalPopup/ModalChatSettlement.tsx index d9179994..d0ef39d3 100644 --- a/packages/web/src/components/ModalPopup/ModalChatSettlement.tsx +++ b/packages/web/src/components/ModalPopup/ModalChatSettlement.tsx @@ -1,7 +1,6 @@ import { useMemo, useRef, useState } from "react"; import useSendMessage from "@/hooks/chat/useSendMessage"; -import { useEvent2024FallQuestComplete } from "@/hooks/event/useEvent2024FallQuestComplete"; import { useValueRecoilState } from "@/hooks/useFetchRecoilState"; import { useAxios } from "@/hooks/useTaxiAPI"; @@ -40,7 +39,6 @@ const ModalChatSettlement = ({ const isValidAccount = useMemo(() => regExpTest.account(account), [account]); const isRequesting = useRef(false); const sendMessage = useSendMessage(roomInfo._id, isRequesting); - const event2024FallQuestComplete = useEvent2024FallQuestComplete(); const onClickOk = () => { if (isRequesting.current || !isValidAccount) return; @@ -57,9 +55,6 @@ const ModalChatSettlement = ({ isRequesting.current = false; if (account !== defaultAccount) openSaveAccountModal?.(account); } - //#region event2024Fall - event2024FallQuestComplete("fareSettlement"); - //#endregion modalProps.onChangeIsOpen?.(false); }, onError: () => { diff --git a/packages/web/src/components/ModalPopup/ModalMypageModify.tsx b/packages/web/src/components/ModalPopup/ModalMypageModify.tsx index b85ed44d..f51fa554 100644 --- a/packages/web/src/components/ModalPopup/ModalMypageModify.tsx +++ b/packages/web/src/components/ModalPopup/ModalMypageModify.tsx @@ -2,7 +2,6 @@ import axiosOri from "axios"; import { useCallback, useEffect, useRef, useState } from "react"; import { useTranslation } from "react-i18next"; -import { useEvent2024FallQuestComplete } from "@/hooks/event/useEvent2024FallQuestComplete"; import { useFetchRecoilState, useValueRecoilState, @@ -144,9 +143,6 @@ const ModalMypageModify = ({ ...modalProps }: ModalMypageModifyProps) => { const loginInfo = useValueRecoilState("loginInfo"); const fetchLoginInfo = useFetchRecoilState("loginInfo"); - //#region event2024Fall - const event2024FallQuestComplete = useEvent2024FallQuestComplete(); - //#endregion const setAlert = useSetRecoilState(alertAtom); useEffect(() => { @@ -169,9 +165,6 @@ const ModalMypageModify = ({ ...modalProps }: ModalMypageModifyProps) => { method: "post", data: { nickname }, onError: () => setAlert(t("page_modify.nickname_failed")), - //#region event2024Fall - onSuccess: () => event2024FallQuestComplete("nicknameChanging"), // event2024Fall - //#endregion }); } if (account !== loginInfo?.account) { @@ -181,9 +174,6 @@ const ModalMypageModify = ({ ...modalProps }: ModalMypageModifyProps) => { method: "post", data: { account }, onError: () => setAlert(t("page_modify.account_failed")), - //#region event2024Fall - onSuccess: () => event2024FallQuestComplete("accountChanging"), // event2024Fall - //#endregion }); } if (isNeedToUpdateLoginInfo) { diff --git a/packages/web/src/components/ModalPopup/ModalNotification.tsx b/packages/web/src/components/ModalPopup/ModalNotification.tsx index fbd19675..9ed2ce85 100644 --- a/packages/web/src/components/ModalPopup/ModalNotification.tsx +++ b/packages/web/src/components/ModalPopup/ModalNotification.tsx @@ -1,7 +1,6 @@ import { useCallback, useRef } from "react"; import { useTranslation } from "react-i18next"; -import { useEvent2024FallQuestComplete } from "@/hooks/event/useEvent2024FallQuestComplete"; import { useFetchRecoilState, useValueRecoilState, @@ -65,9 +64,6 @@ const ModalNotification = ({ const notificationOptions = useValueRecoilState("notificationOptions"); const fetchNotificationOptions = useFetchRecoilState("notificationOptions"); const isAxiosCalled = useRef(false); - //#region event2024Fall - const event2024FallQuestComplete = useEvent2024FallQuestComplete(); - //#endregion const styleTitle = { ...theme.font18, @@ -112,11 +108,6 @@ const ModalNotification = ({ }); fetchNotificationOptions(); isAxiosCalled.current = false; - - //#region event2024Fall - if (optionName === "advertisement" && value) - event2024FallQuestComplete("adPushAgreement"); - //#endregion }, [deviceToken] ); @@ -148,10 +139,6 @@ const ModalNotification = ({ }); fetchNotificationOptions(); isAxiosCalled.current = false; - - //#region event2024Fall - if (value) event2024FallQuestComplete("adPushAgreement"); - //#endregion }, [deviceToken] ); diff --git a/packages/web/src/components/ModalPopup/ModalRoomShare.tsx b/packages/web/src/components/ModalPopup/ModalRoomShare.tsx index 087d04be..0b317aec 100644 --- a/packages/web/src/components/ModalPopup/ModalRoomShare.tsx +++ b/packages/web/src/components/ModalPopup/ModalRoomShare.tsx @@ -1,5 +1,3 @@ -import { useEvent2024FallQuestComplete } from "@/hooks/event/useEvent2024FallQuestComplete"; - import Modal from "@/components/Modal"; import BodyRoomShare, { BodyRoomShareProps } from "./Body/BodyRoomShare"; @@ -19,9 +17,6 @@ const ModalRoomShare = ({ onChangeIsOpen, roomInfo, }: ModalRoomShareProps) => { - //#region event2024Fall - const event2024FallQuestComplete = useEvent2024FallQuestComplete(); - //#endregion const styleTitle = { ...theme.font18, display: "flex", @@ -32,19 +27,9 @@ const ModalRoomShare = ({ fontSize: "21px", margin: "0 4px 0 0", }; - //#region event2024Fall - const onChangeIsOpenWithEvent2024Fall = (isOpen: boolean) => { - onChangeIsOpen?.(isOpen); - !isOpen && event2024FallQuestComplete("roomSharing"); - }; - //#endregion return ( - +
방 공유하기
diff --git a/packages/web/src/pages/Addroom/index.tsx b/packages/web/src/pages/Addroom/index.tsx index 3f1a4a47..172a27f3 100644 --- a/packages/web/src/pages/Addroom/index.tsx +++ b/packages/web/src/pages/Addroom/index.tsx @@ -2,7 +2,6 @@ import { useEffect, useMemo, useRef, useState } from "react"; import { useCookies } from "react-cookie"; import { useHistory } from "react-router-dom"; -import { useEvent2024FallQuestComplete } from "@/hooks/event/useEvent2024FallQuestComplete"; import { useFetchRecoilState, useIsLogin, @@ -12,7 +11,6 @@ import { useAxios } from "@/hooks/useTaxiAPI"; import AdaptiveDiv from "@/components/AdaptiveDiv"; import Button from "@/components/Button"; -import { ModalEvent2024FallAbuseWarning } from "@/components/ModalPopup"; import { OptionDate, OptionMaxPeople, @@ -64,11 +62,6 @@ const AddRoom = () => { const isLogin = useIsLogin(); const myRooms = useValueRecoilState("myRooms"); const fetchMyRooms = useFetchRecoilState("myRooms"); - //#region event2024fall - const event2024FallQuestComplete = useEvent2024FallQuestComplete(); - const [isOpenModalEventAbuseWarning, setIsOpenModalEventAbuseWarning] = - useState(false); - //#endregion const [taxiFare, setTaxiFare] = useState(0); @@ -140,44 +133,6 @@ const AddRoom = () => { const onClickAdd = async () => { if (!onCall.current) { onCall.current = true; - - // #region event2024fall - let isAgreeOnTermsOfEvent = false; - await axios({ - url: "/events/2024fall/globalState", - method: "get", - onSuccess: (data) => { - if (data.isAgreeOnTermsOfEvent) { - isAgreeOnTermsOfEvent = data.isAgreeOnTermsOfEvent; - } - }, - onError: () => {}, - }); - if (isAgreeOnTermsOfEvent) { - let isFalse = false; - await axios({ - url: "/rooms/create/test", - method: "post", - data: { - from: valuePlace[0], - to: valuePlace[1], - time: calculatedTime!.toISOString(), - maxPartLength: valueMaxPeople, - }, - onSuccess: (data) => { - if (data!.result === false) { - setIsOpenModalEventAbuseWarning(true); - onCall.current = false; - isFalse = true; - return; - } - }, - onError: () => {}, - }); - if (isFalse) return; - } - // #endregion - // FIXME: "/rooms/create" API가 myRoom을 반환하도록 수정 await axios({ url: "/rooms/create", @@ -191,9 +146,6 @@ const AddRoom = () => { }, onSuccess: () => { fetchMyRooms(); - //#region event2024fall - event2024FallQuestComplete("firstRoomCreation"); - //#endregion history.push("/myroom"); }, onError: () => setAlert("방 개설에 실패하였습니다."), @@ -253,37 +205,6 @@ const AddRoom = () => { )} - {/* #region event2024Fall */} - { - if (data === true) { - setIsOpenModalEventAbuseWarning(data); - await axios({ - url: "/rooms/create", - method: "post", - data: { - name: valueName || randomRoomName, - from: valuePlace[0], - to: valuePlace[1], - time: calculatedTime!.toISOString(), - maxPartLength: valueMaxPeople, - }, - onSuccess: () => { - fetchMyRooms(); - //#region event2024fall - event2024FallQuestComplete("firstRoomCreation"); - //#endregion - history.push("/myroom"); - }, - onError: () => setAlert("방 개설에 실패하였습니다."), - }); - } else if (data === false) { - setIsOpenModalEventAbuseWarning(data); - } - }} - /> - {/* #endregion */} ) : (