+
응모완료
+
+
+
+
+
+
내 컬렉션 URL
+
+ 링크를 통해 친구가 이벤트를 참여하면 추가 뽑기권을 드려요!
+
+
+
+
+
+
+ {isApplied || (
+
+
+ 새롭게 출시된 아반떼 N에 대한 기대평을 남겨주세요 🥳
+
+
+ 남겨주신 기대평은 홈화면에 노출될 수 있습니다! 최대 50자까지
+ 작성할 수 있어요.
+
+
+
+
+ )}
+
+
+
+
+
+
+ );
+};
diff --git a/packages/service/src/pages/LotteryApplyFinish/index.ts b/packages/service/src/pages/LotteryApplyFinish/index.ts
new file mode 100644
index 00000000..b45090c5
--- /dev/null
+++ b/packages/service/src/pages/LotteryApplyFinish/index.ts
@@ -0,0 +1 @@
+export { LotteryApplyFinish } from "./LotteryApplyFinish";
diff --git a/packages/service/src/pages/PartsPick/PartsPick.tsx b/packages/service/src/pages/PartsPick/PartsPick.tsx
index dc8572d6..4cbb4974 100644
--- a/packages/service/src/pages/PartsPick/PartsPick.tsx
+++ b/packages/service/src/pages/PartsPick/PartsPick.tsx
@@ -10,8 +10,10 @@ import { useEffect, useRef, useState } from "react";
import { useModal } from "@watermelon-clap/core/src/hooks";
import { useAuth } from "@watermelon-clap/core/src/hooks";
import { useMobile } from "@service/common/hooks/useMobile";
-import { useLocation } from "react-router-dom";
+import { useLocation, useNavigate } from "react-router-dom";
import { apiGetPartsRemain } from "@service/apis/partsEvent";
+import { LOTTER_APPLY_FINISH_PAGE_ROUTE } from "@service/constants/routes";
+import { apiGetLotteryStatus } from "@service/apis/lottery/apiGetLotteryStatus";
export const PartsPick = () => {
const { openModal } = useModal();
@@ -22,6 +24,8 @@ export const PartsPick = () => {
useLocation()?.state?.remainChance,
);
const { getIsLogin, login } = useAuth();
+ const navigate = useNavigate();
+ const isApplied = useRef(false);
const minusRemainChance = () => {
if (remainChance < 1) return;
@@ -64,6 +68,8 @@ export const PartsPick = () => {
if (!getIsLogin()) {
login().then(handleSetRemianChance);
}
+
+ apiGetLotteryStatus().then(({ applied }) => (isApplied.current = applied));
}, []);
return (
@@ -82,7 +88,11 @@ export const PartsPick = () => {