후보지 조회 지도 팝업 생성
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import ModalSimilarPage from "@/app/pages/sdmMng/sdmInfoInsert/modalSimilar/page";
|
||||
import type { FormData } from "@/app/pages/sdmMng/sdmInfoInsert/page";
|
||||
import ModalSimilarPage from "@/app/(base-layout)/pages/sdmMng/sdmInfoInsert/modalSimilar/page";
|
||||
import type { FormData } from "@/app/(base-layout)/pages/sdmMng/sdmInfoInsert/page";
|
||||
import { useDmStore } from "@/app/store";
|
||||
import {
|
||||
CANDIDATE,
|
||||
@@ -18,8 +18,8 @@ import { AccessibleFormField } from "./AccessibleFormField";
|
||||
import type { ControllerRenderProps, UseFormReturn } from "react-hook-form";
|
||||
import SearchInputText from "../common/searhDemandInput/component";
|
||||
import type { DemandCompType } from "@/app/store/sdmMng";
|
||||
import NewWindowPortal from "@/app/pages/map/popup/windowPotal";
|
||||
import Map from "@/app/pages/map/popup/sdmInfoMap";
|
||||
import NewWindowPortal from "@/app/(popup-layout)/map/popup/windowPotal";
|
||||
import Map from "@/app/(popup-layout)/map/popup/sdmInfoMap";
|
||||
|
||||
export interface SdmInfoRegFormProps {
|
||||
form: UseFormReturn<FormData>;
|
||||
@@ -82,11 +82,17 @@ export function SdmInfoRegForm({
|
||||
}
|
||||
}, [searchParams, form]);
|
||||
|
||||
const handleCandidateClose = useCallback(
|
||||
() => setIsCandidatePopup(false),
|
||||
[]
|
||||
);
|
||||
|
||||
const searchCandidate = (e: React.MouseEvent) => {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
console.log(1);
|
||||
setIsCandidatePopup(true);
|
||||
//setIsCandidatePopup(true);
|
||||
const popupOptions = `width=1920,height=1080,resizable='y',scrollbars='y'`;
|
||||
window.open('/map/popup', 'title', popupOptions);
|
||||
};
|
||||
|
||||
const searchSimilarCase = (e: React.MouseEvent) => {
|
||||
@@ -610,19 +616,6 @@ export function SdmInfoRegForm({
|
||||
/>
|
||||
)}
|
||||
|
||||
{/* 후보지 조회 새 창 포털 */}
|
||||
{isCandidatePopup && (
|
||||
<NewWindowPortal
|
||||
onClose={() => setIsCandidatePopup(false)}
|
||||
title="공급처 후보지 조회"
|
||||
width={window.screen.availWidth}
|
||||
height={window.screen.availHeight}
|
||||
resizable="no"
|
||||
scrollbars="yes"
|
||||
>
|
||||
<Map />
|
||||
</NewWindowPortal>
|
||||
)}
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user