diff --git a/apps/dm_new/app/(landing)/reuse/apply/modal/SimilarCaseModal.tsx b/apps/dm_new/app/(landing)/reuse/apply/modal/SimilarCaseModal.tsx index f997d88e1..5ea0d03cd 100644 --- a/apps/dm_new/app/(landing)/reuse/apply/modal/SimilarCaseModal.tsx +++ b/apps/dm_new/app/(landing)/reuse/apply/modal/SimilarCaseModal.tsx @@ -71,11 +71,13 @@ export default function SimilarCaseModal({ onClose, rows, detailsByCaseId, + onSearch }: { open: boolean; onClose: () => void; rows: SimilarCaseRow[]; detailsByCaseId: Record; + onSearch :(criterion: Criterion) => void; }) { const titleId = useId(); @@ -192,12 +194,15 @@ export default function SimilarCaseModal({ const v = e.target.value as Criterion; setCriterion(v); setSelectedCaseId(""); + + if(v){ + onSearch(v); + } }} className="h-10 w-[180px] rounded-md border border-neutral-300 bg-white px-3 text-sm outline-none focus:border-neutral-500" > - diff --git a/apps/dm_new/app/(popup-layout)/layout.tsx b/apps/dm_new/app/(popup-layout)/layout.tsx new file mode 100644 index 000000000..742519a66 --- /dev/null +++ b/apps/dm_new/app/(popup-layout)/layout.tsx @@ -0,0 +1,11 @@ +"use client"; +import "../globals.css"; +import { StoreProvider } from "../store"; + +export default function PopupLayout({ + children, +}: Readonly<{ + children: React.ReactNode; +}>) { + return {children}; +} diff --git a/apps/dm_new/app/(popup-layout)/map/popup/page.tsx b/apps/dm_new/app/(popup-layout)/map/popup/page.tsx new file mode 100644 index 000000000..e410ad2a7 --- /dev/null +++ b/apps/dm_new/app/(popup-layout)/map/popup/page.tsx @@ -0,0 +1,274 @@ +"use client"; + +import Gis from "@common/business_components/ui/map/Gis"; +import { useEffect, useRef, useState } from "react"; +import { mapService } from "../service"; +import GisApp from "@common/business_components/ui/map/lib/gis.core"; +import { SearchBar } from "@/components/ui/map/searchBar/searchBar"; +import SelectedFcltList from "./selectedFcltList"; +import type { SubsInfo } from "@/app/store/map/type"; + +const Map = () => { + const [treeData, setTreeData] = useState([]); // 초기값을 객체 또는 null로 설정 + const gisMaps = useRef(null); + const [isOpen, setIsOpen] = useState(false); // 팝업 열기/닫기 상태 + const [isSearchModalOpen, setIsSearchModalOpen] = useState(true); // SearchModal 열림 상태 + const [featureData, setFeatureData] = useState(null); // 선택된 피쳐 데이터 + const [selectDataPk, setSelectDataPk] = useState>({}); + const [selectedFclts, setSelectedFclts] = useState([]); + + //적용 버튼 클릭 이벤트 + const onApply = () => { + if (selectedFclts.length > 3) { + alert("재이용시설 후보지는 최대 3개까지만 선택할 수 있습니다."); + return; + } + + const subsInfoList: SubsInfo[] = selectedFclts.map((fclt) => ({ + ruseUtztnFcltNm: fclt.ruseUtztnFcltNm, + ruseUtztnFcltCd: fclt.pbnstRuseFcltId, + })); + + window.opener.postMessage( + { + type: "SET_SUBS_INFO", + payload: subsInfoList, // 또는 필요한 데이터 + }, + "*" + ); + + window.close(); + }; + + //트리 레이어 데이터 조회 + const fetchData = async () => { + try { + const response = await mapService.getLyrStngs(); + setTreeData(response); // API 응답 저장 + } catch (error) { + console.error("데이터 불러오기 실패:", error); + } + }; + + //하수처리시설코드로 재이용시설 목록 조회 + const reuseData = async (ruseFcltPk: any) => { + try { + const response = await mapService.getPbnstRuseFclts(ruseFcltPk); + const data = response.data || []; + setSelectedFclts((prev) => { + const newItems = data.filter( + (item: any) => + item && + Object.keys(item).length > 0 && + !prev.some((f) => f.pbnstRuseFcltId === item.pbnstRuseFcltId) + ); + console.log(newItems); + return [...prev, ...newItems]; + }); + } catch (error) { + console.error("데이터 불러오기 실패:", error); + } + }; + + // 컴포넌트 마운트 시 1회 실행 + useEffect(() => { + fetchData(); + }, []); + + // 레이어 생성 후 초기화 처리 + const onCheckedLayersChange = () => { + //수요처 ID + const urlParams = new URLSearchParams(window.location.search); + const dmdInfoId = urlParams.get("dmdInfoId"); + + //수요처 위치로 화면 이동 + const maps = gisMaps.current; + const layer = GisApp.Module.layer as any; + const layerNm = "tb_wr_ruse_fclt_dmd_co"; + const featureId = `${layerNm}.${dmdInfoId}`; + let foundFeature: any = null; + + maps + .getLayers() + .getArray() + .forEach((layer: any) => { + if (layer.get("lyrTyNm") == layerNm) { + const source = layer.getSource?.(); + if (source?.getFeatureById) { + const feature = source.getFeatureById(String(featureId).trim()); + if (feature) { + foundFeature = feature; + return; + } + } + } + }); + + if (foundFeature) { + const geometry = foundFeature.getGeometry(); + + if (geometry) { + const extent = geometry.getExtent(); + + if (geometry.getType() === "Point") { + maps.getView().setCenter(geometry.getCoordinates()); + maps.getView().setZoom(11); + } else { + maps.getView().fit(extent, { + duration: 300, + padding: [30, 30, 30, 30], + maxZoom: 16, + }); + } + } + + layer.highLightFeature( + [foundFeature], + { + id: GisApp.hlLayerId, + zIndex: 10, + opacity: 1, + selectable: true, + }, + { width: 30 } + ); + } else { + alert("수요처의 좌표정보를 찾을수 없으므로, 상단 조회조건의 시설명을 입력하여 위치를 조회하시기 바랍니다."); + } + + const formatNumber = (val: any) => { + const num = Number(val); + return isNaN(num) ? "-" : num.toLocaleString(); + }; + + // 재이용시설 오버레이 + maps + .getLayers() + .getArray() + .forEach((layer: any) => { + if (layer.get("lyrTyNm") === "tb_wr_bdst_ruse_fclt") { + const source = layer.getSource?.(); + if (source?.getFeatures) { + const features = source.getFeatures(); + + features.forEach((feature: any) => { + // 필요한 고유 ID 또는 속성 가져오기 (예: ftrIdn 또는 feature.getId()) + const featureId = + feature.getId() || feature.get("ftrIdn") || Math.random(); + + // HTML 또는 React 오버레이 컴포넌트 구성 + const overlayContent = ` +
+ +
+ ${feature.get("swtrmt_fclt_nm") || "-"} +
+ + + + + + + + + +
용량(m³/일)${formatNumber(feature.get("fclt_cpct"))}
+
+ `; + feature.set("html", overlayContent); + feature.set("overLayId", `overLay.${featureId}`); + }); + } + } + }); + }; + + // 검색해서 재이용시설 선택하면 해당 시설로 화면 이동 처리 + useEffect(() => { + if (!selectDataPk || Object.keys(selectDataPk).length === 0) return; + const maps = gisMaps.current; + let foundFeature: any = null; + const layerNm = "tb_wr_bdst_ruse_fclt"; + const featureId = `${layerNm}.${selectDataPk.bscFctCd}`; + maps + .getLayers() + .getArray() + .forEach((layer: any) => { + if (layer.get("lyrTyNm") == layerNm) { + const source = layer.getSource?.(); + if (source?.getFeatureById) { + const feature = source.getFeatureById(String(featureId).trim()); + if (feature) { + foundFeature = feature; + return; + } + } + } + }); + + if (foundFeature) { + const geometry = foundFeature.getGeometry(); + if (geometry) { + const extent = geometry.getExtent(); + + maps.getView().fit(extent, { + duration: 300, + padding: [50, 50, 50, 50], + maxZoom: 16, + constrainResolution: true, + nearest: true, + }); + } + } else { + console.warn("OpenLayers Feature를 찾을 수 없습니다:", selectDataPk); + } + }, [selectDataPk]); + + // 재이용시설 클릭 시 선택 시설목록에 추가 + const onFeatureSelect = (data: any) => { + // 처리시설코드 + const swtrmtFcltCd = data.get("swtrmt_fclt_cd"); + reuseData(swtrmtFcltCd); + }; + + return ( + <> +
+ { + if (hasuPk) setSelectDataPk(hasuPk); + }} + onApply={onApply} + /> + } + waterDepth={undefined} + /> +
+ setSelectedFclts(updatedList)} + /> + + ); +}; + +export default Map; diff --git a/apps/dm_new/app/(popup-layout)/map/popup/selectedFcltList.tsx b/apps/dm_new/app/(popup-layout)/map/popup/selectedFcltList.tsx new file mode 100644 index 000000000..bdf4d7e2c --- /dev/null +++ b/apps/dm_new/app/(popup-layout)/map/popup/selectedFcltList.tsx @@ -0,0 +1,81 @@ +import React from "react"; + +type FcltItem = { + pbnstRuseFcltId: string; + ruseUtztnFcltNm: string; + splyExtraCpct?: number; + ruseCpct?: number; + [key: string]: any; +}; + +export default function SelectedFcltList({ + data = [], + onRemove, +}: { + data: FcltItem[]; + onRemove: (updatedList: FcltItem[]) => void; +}) { + const handleDelete = (code: string) => { + const updatedList = data.filter((item) => item.pbnstRuseFcltId !== code); + onRemove(updatedList); + }; + + const TableContent = ( + <> + + + 시설명 + + 하수처리량 +
+ (㎥/일) + + + 재이용량 +
+ (㎥/일) + + 삭제 + + + + {data.map((item) => ( + + {item.ruseUtztnFcltNm} + + {Number(item.splyExtraCpct || 0).toLocaleString()} + + + {Number(item.ruseCpct || 0).toLocaleString()} + + + + + + ))} + + + ); + + if (data.length === 0) return null; + + return ( +
+

+ 선택된 시설 +

+
+ + {TableContent} +
+
+
+ ); +} diff --git a/apps/dm_new/app/(popup-layout)/map/service/index.ts b/apps/dm_new/app/(popup-layout)/map/service/index.ts new file mode 100644 index 000000000..c6bfcff72 --- /dev/null +++ b/apps/dm_new/app/(popup-layout)/map/service/index.ts @@ -0,0 +1 @@ +export * from './map' diff --git a/apps/dm_new/app/(popup-layout)/map/service/map.ts b/apps/dm_new/app/(popup-layout)/map/service/map.ts new file mode 100644 index 000000000..00e3ab561 --- /dev/null +++ b/apps/dm_new/app/(popup-layout)/map/service/map.ts @@ -0,0 +1,59 @@ +/** + * 관망도 API + */ +import { DEV_URL_WR, DEV_URL_SN } from "@/components/ui/config"; + +export type LyrStngProps = { + lyr_sn: string + lyr_nm: string + upper_lyr_sn: string + drawOrdr: string + flterSql: string + gobjTy: string + lyrTpNm: string + useYn: string + minViewSize: string + iconNm: string + lblAtrbNm: string + fontNm: string + fontIntnColor: string + fontExtnColor: string + fontExtnWdth: string + lnWdth: string + lnColor: string + polgnColor: string + initEprssYn: string + clickPsblYn: string +} + +export const mapService = { + //레이어 설정 조회 + getLyrStngs: async () => { + const response = await fetch(`${DEV_URL_SN}/api/v1/map/lyrStngs/DM_NETWORK`, { + method: 'GET', + headers: { + 'Accept': 'application/json', + }, + }); + + if (!response.ok) { + throw new Error(`HTTP error! status: ${response.status}`); + } + + return response.json(); + }, + getPbnstRuseFclts: async (ruseFcltPk:any) => { + const response = await fetch(`${DEV_URL_WR}/reuseFc/pubFc/${ruseFcltPk}`, { + method: 'GET', + headers: { + 'Accept': 'application/json', + }, + }); + + if (!response.ok) { + throw new Error(`HTTP error! status: ${response.status}`); + } + + return response.json(); + } +} diff --git a/apps/dm_new/app/(with-layout)/apply/register/page.tsx b/apps/dm_new/app/(with-layout)/apply/register/page.tsx index 3c084bf73..24f2e5918 100644 --- a/apps/dm_new/app/(with-layout)/apply/register/page.tsx +++ b/apps/dm_new/app/(with-layout)/apply/register/page.tsx @@ -8,10 +8,13 @@ */ "use client"; -import { useMemo, useState, useRef } from "react"; +import { useMemo, useState, useRef, useEffect } from "react"; import SubPageHeader from "@/components/SubPageHeader"; import WaterQualityRefModal from "../modal/WaterQualityRefModal"; import CandidateSiteModal, { type CandidateSite } from "@/components/CandidateSiteModal"; +import { useDmStore} from "@/app/store"; +import type { SdmInfoFormData } from "@/app/store/sdmMng"; +import SimilarCaseModal, { type SimilarCaseDetail, type SimilarCaseRow } from "@/app/(landing)/reuse/apply/modal/SimilarCaseModal"; type PHRange = { min: string; max: string }; @@ -36,7 +39,7 @@ export default function DemandRegisterPage() { const [hopePrice, setHopePrice] = useState(""); // 요구수질 - const [coliform, setColiform] = useState(""); + const [coliform, setColiform] = useState(""); // 총대장균군수 const [noDetect, setNoDetect] = useState(false); const [tn, setTn] = useState(""); @@ -56,6 +59,214 @@ export default function DemandRegisterPage() { const [cand2, setCand2] = useState(""); const [cand3, setCand3] = useState(""); + const useTypesData = useDmStore((state) => state.Sdm.useTypesData); + const getUseTypesData = useDmStore((state) => state.getUseTypesData); + const [openSimilar, setOpenSimilar] = useState(false); + + // 유사사례 + const similarCaseList = useDmStore((state) => state.Sdm.similarCaseList); + const getSimilarCaseList = useDmStore((state) => state.getSimilarCaseList); + + + const insertSdmInfoData = useDmStore( + (state) => state.insertSdmInfoData + ); + + useEffect(() => { + getUseTypesData(); + }, [getUseTypesData]); + + // option + // 'req':필수 / 'num' : 숫자 / 'num+[숫자] : 자릿수 + const validation = (val, text, option :string[]=[] ) => { + if(option.includes('req')){ + if(val.trim() === "" || val ===undefined) { + alert(`${text} 항목은 필수 입력값입니다.`); + return false; + } + }else{ + if(val.trim()===""){ + return true; + } + } + + const numOption = option.find((opt) => opt.startsWith("num")); + if (numOption) { + const isDot = numOption.includes("Dot"); + + // 3. 숫자 체크 + const regex = isDot ? /^\d+(\.\d+)?$/ : /^\d+$/; + + if (!regex.test(val)) { + alert( + `${text}은(는) ${ + isDot ? "숫자 또는 소수" : "숫자" + }만 입력 가능합니다.` + ); + return false; + } + + // 4. 자리수 체크 + const lengthStr = numOption.replace("numDot", "").replace("num", ""); + + if (lengthStr) { + const length = Number(lengthStr); + + if (isDot) { + // 🔥 소수 자리수 체크 (소수점 기준) + const decimalPart = val.split(".")[1]; + + if (decimalPart && decimalPart.length > length) { + alert(`${text}은(는) 소수점 ${length}자리까지 가능합니다.`); + return false; + } + } else { + // 정수 자리수 체크 + if (val.length !== length) { + alert(`${text}은(는) ${length}자리여야 합니다.`); + return false; + } + } + } + } + return true; + } + + const rows: SimilarCaseRow[] = similarCaseList.map((el, idx) => ({ + caseId: String(idx), + projectName: el.ruseBizNm, + period: `${el.bizBgngDate} ~ ${el.bizEndDate}`, + + supplyFacilityType: el.splyFcltKnd, + supplyName: el.splyFcltNm, + supplyCapacity: Number(el.splyFcltCpct), + + demandName: el.dmdFcltNm, + demandAddress: el.dmdFcltAddr, + + facilityCapacity: Number(el.ruseFcltCpct), + pipeKm: Number(el.ruseFcltPplLen), + purpose: el.ruseFcltUsg, + + supplyAmt: Number(el.ruseFcltSplyCpct), + treatment: el.ruseFcltPrcsMsrc, + usePurpose: el.ruseFcltUsg, + })); + + const detailsByCaseId: Record = {}; + similarCaseList.forEach((el, idx) => { + detailsByCaseId[String(idx)] = { + coliform: el.grnteWqGrssClfg, + residualCl: el.grnteWqCombResdch, + turbidity: el.grnteWqTrbt, + bod: el.grnteWqBod, + odor: el.grnteWqSmll, + color: el.grnteWqCrmty, + tn: el.grnteWqTn, + tp: el.grnteWqTp, + ph: el.grnteWqPh, + chloride: el.grnteWqClIonQnt, + ec: el.grnteWqCndctStat, + note: el.grnteWqRmrk, + + costTotal: Number(el.reqBizGrssCst), + costFacility: Number(el.reqBizReuseFcltCst), + costPipe: Number(el.reqBizPplCst), + costDesign: Number(el.reqBizDesignCst), + costSupervision: Number(el.reqBizSpvsCst), + costOther: Number(el.reqBizEtc), + + fundingTotal: Number(el.prcmPlanGrssCst), + fundingNational: Number(el.prcmPlanNlep), + fundingLocal: Number(el.prcmPlanLcep), + fundingSelf: Number(el.prcmPlanBrdnCst), + fundingRate: Number(el.prcmPlanEcqrRt), + }; + }); + + // 데이터 저장 + const saveInfo = async() => { + if(!validation(reqQty, '요구수량', ['req', 'numDot'])) return false; + if(!validation(usePurpose, '사용용도', ['req'])) return false; + if(!validation(hopePrice, '희망단가', ['req', 'numDot'])) return false; + if(!noDetect && !validation(coliform, '총대장균군수', ['req','numDot'])) return false; + if(!validation(residualCl, ['req', '결합잔류염소', 'numDot'])) return false; + if(!validation(turbidity, '탁도', ['req', 'numDot'])) return false; + if(!validation(bod, '생물화학적산소요구량', ['req', 'numDot'])) return false; + if(!validation(odor, '냄새', ['req'])) return false; + + // 필수는 아니지만 숫자로는 들어와야함. + if(!validation(tn, '총질소', ['numDot'])) return false; + if(!validation(residualCl, '결합잔류염소', ['numDot'])) return false; + if(!validation(tp, '총인', ['numDot'])) return false; + if(!validation(ph.min, 'ph', ['numDot'])) return false; + if(!validation(ph.max, 'ph', ['numDot'])) return false; + if(!validation(chloride, '염화물', ['numDot'])) return false; + if(!validation(ec, '전기전도도', ['numDot'])) return false; + + const userStr = sessionStorage.getItem("user"); + const user = userStr ? JSON.parse(userStr) : null; + + if(user){ + const payload : SdmInfoFormData = { + dmndTmng : new Date(reqDate), + dmdInfoId : user.dmdInfoId, + dmndQty : Number(reqQty), + wntUntprc : Number(hopePrice), + useUsgCd : usePurpose, + // 수질 + grssClfg : Number(coliform), + tn : Number(tn)||null, + combResdch: Number(residualCl)||null, + tph : Number(tp)||null, + trbt : Number(turbidity), + ph : ph.min||''+((ph.min||ph.max)?'~':'')+ph.max||'', + blgcOxygDmndQnt : Number(bod), + clIonQnt : Number(chloride)||null, + smll : odor, + cdtnv : Number(ec)||null, + crmty : Number(color)||null, + rmrk : remark + } + insertSdmInfoData(payload); + } + } + + const searchCandidate = (e: React.MouseEvent) => { + e.preventDefault(); + e.stopPropagation(); + const dmdInfoId = JSON.parse( + sessionStorage.getItem("user") || "{}" + )?.dmdInfoId?.toString(); + + const url = `/map/popup?dmdInfoId=${encodeURIComponent(dmdInfoId)}`; + const width = window.screen.availWidth; + const height = window.screen.availHeight; + const left = 0; + const top = 0; + const popupOptions = `width=${width},height=${height},left=${left},top=${top},resizable=yes,scrollbars=yes`; + window.open(url, "candidatePopup", popupOptions); + }; + + const getCriterionCode = (criterion: string) => { + switch (criterion) { + case "supplyAmt": + return "S"; + case "money": + return "M"; + case "usePurpose": + return "U"; + default: + return ""; + } + }; + + const searchSimilarCase = async (e: React.MouseEvent) => { + e.preventDefault(); + e.stopPropagation(); + setOpenSimilar(true); + }; + return ( <> @@ -89,7 +300,18 @@ export default function DemandRegisterPage() { - + @@ -262,16 +484,21 @@ export default function DemandRegisterPage() { + - + setOpenSimilar(false)} + rows={rows} // 실제 데이터 + detailsByCaseId={detailsByCaseId} + onSearch={async (criterion) => { + const code = getCriterionCode(criterion); + if (!code) return; + // 값은 상황에 맞게 (예시: usePurpose) + await getSimilarCaseList(code, code=='S'?reqQty:code=='U'?usePurpose:''); + }} + /> + setOpenCand(false)} diff --git a/apps/dm_new/app/store/sdmMng/index.tsx b/apps/dm_new/app/store/sdmMng/index.tsx index 393f2503b..539bcd629 100644 --- a/apps/dm_new/app/store/sdmMng/index.tsx +++ b/apps/dm_new/app/store/sdmMng/index.tsx @@ -1,4 +1,4 @@ -import { fetchType, getFetch, postFetch } from "@/components/ui/api"; +import { fetchType, getFetch, postFetch, getFetchWithCount } from "@/components/ui/api"; import type { SelectDataType } from "@common/business_components/ui"; import type { TableUpperProps } from "../common"; import toast from "react-hot-toast"; @@ -10,34 +10,27 @@ import { z } from "zod"; =====================================*/ export const sdmInfoFormSchema = z.object({ - sdmNm: z.string().min(1, "수요처를 선택해주세요"), - demandYmd: z.date().optional(), - demandQnty: z - .string() - .min(1, "요구수량을 입력해주세요") - .regex(/^[0-9]+$/, "요구수량은 숫자만 입력 가능합니다"), - usePurpose: z.string().optional(), - money: z.string().regex(/^[0-9]+$/, "희망단가는 숫자만 입력 가능합니다"), - /**요구수질 */ - reqWaterQlty: z.string().optional(), + dmdInfoId: z.string().optional(), + dmndTmng: z.date().optional(), + dmndQty: z.number().min(1, "요구수량을 입력해주세요"), + wntUntprc: z.number().min(1, "희망단가를 입력해주세요"), + useUsgCd: z.string().min(1, "사용용도를 선택해주세요"), + /** 수질 */ grssClfg: z.number().nullish(), tn: z.number().nullish(), combResdch: z.number().nullish(), tph: z.number().nullish(), trbt: z.number().nullish(), ph: z.string().nullish(), - bod: z.number().nullish(), - /**컬럼확인필요 */ + blgcOxygDmndQnt: z.number().nullish(), clIonQnt: z.number().nullish(), smll: z.string(), cdtnv: z.number().nullish(), crmty: z.number().nullish(), + rmrk: z.string().optional(), - /* telno: z.string() - .min(8, "전화번호는 8자 이상 입력해주세요") - .max(12, "전화번호는 12자 이내로 입력해주세요") - .regex(/^[0-9-]+$/, "전화번호는 숫자와 하이픈(-)만 입력 가능합니다"), */ - candidateTitle: z + + splyCndtList: z .array( z.object({ ruseUtztnFcltNm: z.string(), @@ -45,58 +38,6 @@ export const sdmInfoFormSchema = z.object({ }) ) .optional(), -}).superRefine((data, ctx) => { - const disabledFields = disableRules[data.usePurpose ?? ""] || []; - // 모든 수질 관련 필드 - // 총대장균군수는 null 값을 불검출로 표시하기때문에 해당 검사에서 제외함. - const allFields: (keyof typeof data)[] = [ - "tn", "combResdch", "tph", - "trbt", "ph", "bod", "clIonQnt", - "smll", "cdtnv", "crmty", - ]; - - const allFieldsName: Record = { - tn: "총질소(T-N)(mg/L)", - combResdch: "결합잔류염소(mg/L)", - tph: "총인(T-P)(mg/L)", - trbt: "탁도(NTU)", - ph: "수소이온농도(pH)", - bod: "생물학적 산소요구량(BOD)(mg/L)", - clIonQnt: "염화물(mgCL/L)", - smll: "냄새", - cdtnv: "전기전도도(㎲/cm)", - crmty: "색도(도)", - }; - allFields.forEach((field) => { - const isDisabled = disabledFields.includes(field); - if (!isDisabled) { - // disabled가 아닌 필드는 반드시 값이 있어야 함 - const value = data[field]; - if (typeof value === "string") { - if (value.trim().length === 0) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: [field], - message: `${allFieldsName[field]} 을 입력해주세요.`, - }); - } - } else if (typeof value === "number") { - if (value <= 0 || Number.isNaN(value)) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: [field], - message: `${allFieldsName[field]} 을 입력해주세요.`, - }); - } - } else if (value == null) { - ctx.addIssue({ - code: z.ZodIssueCode.custom, - path: [field], - message: `${allFieldsName[field]} 을 입력해주세요.`, - }); - } - } - }); }); export type SdmInfoFormData = z.infer; @@ -394,7 +335,7 @@ const defaultRules: Record = { // 사용용도 const useTypesData: SelectDataType[] = [ - { text: '청소', val: "청소" }, +/* { text: '청소', val: "청소" }, { text: "화장실용수", val: "화장실용수" }, { text: "세척", val: "세척" }, { text: "살수", val: "살수" }, @@ -402,7 +343,7 @@ const useTypesData: SelectDataType[] = [ { text: "농업_간접용수", val: "농업_간접용수" }, { text: "농업_직접용수", val: "농업_직접용수" }, { text: "하천", val: "하천" }, - { text: "공업", val: "공업" }, + { text: "공업", val: "공업" }, */ ]; // 유사사례 모달 헤더 @@ -513,13 +454,13 @@ const postSdmData = async (data: DemandCompType) => { } // 수요정보 등록 -const postSdmInfoData = async (data: DemandCompBizType) => { +const postSdmInfoData = async (data: SdmInfoFormData) => { try { await postFetch("/reuseFc/request/demandInfo", data); - toast.success('수요 정보 등록에 성공하였습니다.'); + alert('수요 정보 등록에 성공하였습니다.'); } catch (error) { console.log(error); - toast.error('수요 정보 등록에 실패하였습니다.'); + alert('수요 정보 등록에 실패하였습니다.'); } } @@ -595,12 +536,14 @@ const fetchGetSimilarCaseList = async (part: string, value: number | string) => export type SdmActions = { initializeSdmData: () => void; insertSdmData: (data: DemandCompType) => Promise; - insertSdmInfoData: (data: DemandCompBizType) => Promise; + insertSdmInfoData: (data: SdmInfoFormData) => Promise; getDemandCompList: (searchText: string, pageCnt: number) => Promise; actionLogin: (data: DemandCompType) => Promise; getSdmInfoStatusList: (dmdInfoId: string) => Promise; getSimilarCaseList: (part: string, value: number | string) => Promise; actionLogout: () => Promise; + + getUseTypesData: () => Promise; } export type SdmType = { @@ -668,7 +611,7 @@ export const SdmReducer = (set: any): SdmActions => { } }, - insertSdmInfoData: async (data: DemandCompBizType) => { + insertSdmInfoData: async (data: SdmInfoFormData) => { postSdmInfoData(data); }, @@ -795,6 +738,24 @@ export const SdmReducer = (set: any): SdmActions => { successLogin: false, } })) + }, + + getUseTypesData: async () => { + //http://dev.onasys.co.kr:3000/server/cms-service/api/v1/lwpo-cds?lwpoCdNm=&sort=regDt,desc&upCd=WR018&page=0&size=10 + + const upCd = await getFetchWithCount( + fetchType.CS, + "/cms-service/api/v1/lwpo-cds/?lwpoCdNm=&sort=regDt,desc&upCd=WR018&page=0&size=100" + ); + + const comUseTypes = upCd.content.filter(el=>el.lwpoCdNm != '친수용수').map((el: any) => ({ text: el.lwpoCdNm, val: el.lwpoCd })); + + set((state: SdmType) => ({ + Sdm: { + ...state.Sdm, + useTypesData: comUseTypes, + } + })); } } } diff --git a/apps/dm_new/components/ui/api/index.ts b/apps/dm_new/components/ui/api/index.ts index abb0c2c73..49d244d25 100644 --- a/apps/dm_new/components/ui/api/index.ts +++ b/apps/dm_new/components/ui/api/index.ts @@ -1,6 +1,7 @@ //8880 import { AUTH_USER_ID, CLAIM_NAME } from "@/src/shared/config"; import { getCookie } from "@common/components/lib/cookie"; +import { DEV_URL_FO, DEV_URL_WR, LOCAL_URL } from "../config/"; const tokenId = getCookie(AUTH_USER_ID); @@ -10,7 +11,9 @@ export const fetchType = { COMMON: "common", WR: "wr", FO: "fo", - SN: "sn" + SN: "sn", + LOCAL: "LOCAL", + CS: "CS", }; const API_VERSION = "/api/v1" @@ -44,6 +47,55 @@ export const getFetch = async (type: string, url: string) => { return res; }; +export const getFetchWithCount = async (type: string, url: string) => { + const div = + type === fetchType.COMMON + ? DEV_URL_FO + : type === fetchType.LOCAL + ? LOCAL_URL + : type === fetchType.CS + ? "" + : DEV_URL_WR; + const apiUrl = div + url; + + const response = await fetch(apiUrl, { + method: "GET", + headers: { + accept: "application/json", + }, + }); + + if (!response.ok) { + console.log(`오류 발생: ${response.status}`); + } + + const contentType = response.headers.get("content-type") ?? ""; + + if (contentType.includes("application/json")) { + // JSON 응답 처리 + const res = await response.json(); + + return res; + } else if(contentType.includes('application/octet-stream')) { + // 파일 응답 처리 (ex. PDF, Excel 등) + + console.log('contentType ' ,contentType) + const blob = await response.blob(); + const blobUrl = window.URL.createObjectURL(blob); + const a = document.createElement("a"); + const filename = "downloaded_file.PDF"; + + a.href = blobUrl; + a.download = filename; + a.click(); + window.URL.revokeObjectURL(blobUrl); + + return null; // 다운로드이므로 반환값 없음 + }else{ + throw Error('오류 발생') + } +}; + export const postFetch = async (url: string, params: RequestParams) => { const baseUrl = servers[fetchType.WR]; const response = await fetch(baseUrl + url, { diff --git a/apps/dm_new/public/images/map/help.png b/apps/dm_new/public/images/map/help.png new file mode 100644 index 000000000..e872802e4 Binary files /dev/null and b/apps/dm_new/public/images/map/help.png differ diff --git a/apps/dm_new/public/images/map/layericon/BML_CBAS_PS.png b/apps/dm_new/public/images/map/layericon/BML_CBAS_PS.png new file mode 100644 index 000000000..0e70939ba Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/BML_CBAS_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/BML_ELEV_PS.png b/apps/dm_new/public/images/map/layericon/BML_ELEV_PS.png new file mode 100644 index 000000000..83970a331 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/BML_ELEV_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/BML_ETCP_PS.png b/apps/dm_new/public/images/map/layericon/BML_ETCP_PS.png new file mode 100644 index 000000000..df9e4957b Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/BML_ETCP_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/BML_STMS_PS.png b/apps/dm_new/public/images/map/layericon/BML_STMS_PS.png new file mode 100644 index 000000000..bf4357181 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/BML_STMS_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/BML_SYMB_PS.png b/apps/dm_new/public/images/map/layericon/BML_SYMB_PS.png new file mode 100644 index 000000000..497589bea Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/BML_SYMB_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_BYST_PS.png b/apps/dm_new/public/images/map/layericon/RDL_BYST_PS.png new file mode 100644 index 000000000..1e78cba68 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_BYST_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_CROS_PS.png b/apps/dm_new/public/images/map/layericon/RDL_CROS_PS.png new file mode 100644 index 000000000..57b5f2ca5 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_CROS_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_ETCT_PS.png b/apps/dm_new/public/images/map/layericon/RDL_ETCT_PS.png new file mode 100644 index 000000000..e5a83f998 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_ETCT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_OCUP_PS.png b/apps/dm_new/public/images/map/layericon/RDL_OCUP_PS.png new file mode 100644 index 000000000..aeae3e266 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_OCUP_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_RDSN_PS.png b/apps/dm_new/public/images/map/layericon/RDL_RDSN_PS.png new file mode 100644 index 000000000..5629de9fb Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_RDSN_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_SCLT_PS.png b/apps/dm_new/public/images/map/layericon/RDL_SCLT_PS.png new file mode 100644 index 000000000..7281dc61d Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_SCLT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_SEPC_PS.png b/apps/dm_new/public/images/map/layericon/RDL_SEPC_PS.png new file mode 100644 index 000000000..b3db8e0a4 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_SEPC_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_STAT_PS.png b/apps/dm_new/public/images/map/layericon/RDL_STAT_PS.png new file mode 100644 index 000000000..9a0b11673 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_STAT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_STLT_PS.png b/apps/dm_new/public/images/map/layericon/RDL_STLT_PS.png new file mode 100644 index 000000000..489524b5c Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_STLT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_TFSN_PS.png b/apps/dm_new/public/images/map/layericon/RDL_TFSN_PS.png new file mode 100644 index 000000000..6dfff6696 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_TFSN_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_TRCT_PS.png b/apps/dm_new/public/images/map/layericon/RDL_TRCT_PS.png new file mode 100644 index 000000000..ed1a72d8a Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_TRCT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_TREE_PS.png b/apps/dm_new/public/images/map/layericon/RDL_TREE_PS.png new file mode 100644 index 000000000..0ee84dedc Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_TREE_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_TRSN_PS.png b/apps/dm_new/public/images/map/layericon/RDL_TRSN_PS.png new file mode 100644 index 000000000..15675cb31 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_TRSN_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_TSCT_PS.png b/apps/dm_new/public/images/map/layericon/RDL_TSCT_PS.png new file mode 100644 index 000000000..3776f6c04 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_TSCT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/RDL_TSCT_PS500.png b/apps/dm_new/public/images/map/layericon/RDL_TSCT_PS500.png new file mode 100644 index 000000000..b82e2ff89 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/RDL_TSCT_PS500.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_CLAY_PS.png b/apps/dm_new/public/images/map/layericon/SWL_CLAY_PS.png new file mode 100644 index 000000000..e603ffa9c Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_CLAY_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_CLAY_PS_RED.png b/apps/dm_new/public/images/map/layericon/SWL_CLAY_PS_RED.png new file mode 100644 index 000000000..0e5450688 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_CLAY_PS_RED.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_DEPT_PS.png b/apps/dm_new/public/images/map/layericon/SWL_DEPT_PS.png new file mode 100644 index 000000000..fede6c304 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_DEPT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_MANH_PS.png b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS.png new file mode 100644 index 000000000..75217f494 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_BLACK.png b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_BLACK.png new file mode 100644 index 000000000..5d2e8a70a Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_BLACK.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_BLUE.png b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_BLUE.png new file mode 100644 index 000000000..e521cb84a Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_BLUE.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_GRAY.png b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_GRAY.png new file mode 100644 index 000000000..e19f3d8b3 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_GRAY.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_GREEN.png b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_GREEN.png new file mode 100644 index 000000000..4503c13c6 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_GREEN.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_ORANGE.png b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_ORANGE.png new file mode 100644 index 000000000..288d1afa8 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_ORANGE.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_RED.png b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_RED.png new file mode 100644 index 000000000..b8fa45f9c Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_RED.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_YELLOW.png b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_YELLOW.png new file mode 100644 index 000000000..b7de1fbfd Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_MANH_PS_YELLOW.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_SPEW_PS.png b/apps/dm_new/public/images/map/layericon/SWL_SPEW_PS.png new file mode 100644 index 000000000..d260ea3a6 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_SPEW_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS.png b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS.png new file mode 100644 index 000000000..84c7992e4 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_BLACK.png b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_BLACK.png new file mode 100644 index 000000000..fe67f8f98 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_BLACK.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_BLUE.png b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_BLUE.png new file mode 100644 index 000000000..691f2f45e Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_BLUE.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_GREEN.png b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_GREEN.png new file mode 100644 index 000000000..d09c4bd97 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_GREEN.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_GREY.png b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_GREY.png new file mode 100644 index 000000000..32d0bf519 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_GREY.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_RED.png b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_RED.png new file mode 100644 index 000000000..a2da36f9b Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_SPOT_PS_RED.png differ diff --git a/apps/dm_new/public/images/map/layericon/SWL_VENT_PS.png b/apps/dm_new/public/images/map/layericon/SWL_VENT_PS.png new file mode 100644 index 000000000..834eeec21 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/SWL_VENT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/TL_SPBD_ENTRC.png b/apps/dm_new/public/images/map/layericon/TL_SPBD_ENTRC.png new file mode 100644 index 000000000..8e7de8593 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/TL_SPBD_ENTRC.png differ diff --git a/apps/dm_new/public/images/map/layericon/TL_SPGF_LOC.png b/apps/dm_new/public/images/map/layericon/TL_SPGF_LOC.png new file mode 100644 index 000000000..74b0adac3 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/TL_SPGF_LOC.png differ diff --git a/apps/dm_new/public/images/map/layericon/TL_SPOT_NOIN.png b/apps/dm_new/public/images/map/layericon/TL_SPOT_NOIN.png new file mode 100644 index 000000000..4800beaeb Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/TL_SPOT_NOIN.png differ diff --git a/apps/dm_new/public/images/map/layericon/TL_SPRD_BANO.png b/apps/dm_new/public/images/map/layericon/TL_SPRD_BANO.png new file mode 100644 index 000000000..8d08dca29 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/TL_SPRD_BANO.png differ diff --git a/apps/dm_new/public/images/map/layericon/TL_SPRD_CRSRD.png b/apps/dm_new/public/images/map/layericon/TL_SPRD_CRSRD.png new file mode 100644 index 000000000..57b5f2ca5 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/TL_SPRD_CRSRD.png differ diff --git a/apps/dm_new/public/images/map/layericon/TL_SPRD_NONM.png b/apps/dm_new/public/images/map/layericon/TL_SPRD_NONM.png new file mode 100644 index 000000000..e68c05ab6 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/TL_SPRD_NONM.png differ diff --git a/apps/dm_new/public/images/map/layericon/TL_SPRD_RENM.png b/apps/dm_new/public/images/map/layericon/TL_SPRD_RENM.png new file mode 100644 index 000000000..4800beaeb Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/TL_SPRD_RENM.png differ diff --git a/apps/dm_new/public/images/map/layericon/TL_SPRD_RWNM.png b/apps/dm_new/public/images/map/layericon/TL_SPRD_RWNM.png new file mode 100644 index 000000000..e68c05ab6 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/TL_SPRD_RWNM.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_BMAN_PS.png b/apps/dm_new/public/images/map/layericon/UFL_BMAN_PS.png new file mode 100644 index 000000000..f2f64a641 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_BMAN_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_BOPC_PS.png b/apps/dm_new/public/images/map/layericon/UFL_BOPC_PS.png new file mode 100644 index 000000000..0f8e99f45 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_BOPC_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_BPIP_PS.png b/apps/dm_new/public/images/map/layericon/UFL_BPIP_PS.png new file mode 100644 index 000000000..dcc3622a7 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_BPIP_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_BPOL_PS.png b/apps/dm_new/public/images/map/layericon/UFL_BPOL_PS.png new file mode 100644 index 000000000..4f1102989 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_BPOL_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_BTRS_PS.png b/apps/dm_new/public/images/map/layericon/UFL_BTRS_PS.png new file mode 100644 index 000000000..557c17089 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_BTRS_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_GMNT_PS.png b/apps/dm_new/public/images/map/layericon/UFL_GMNT_PS.png new file mode 100644 index 000000000..6081d8b00 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_GMNT_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_GPIP_PS.png b/apps/dm_new/public/images/map/layericon/UFL_GPIP_PS.png new file mode 100644 index 000000000..5d7e86fd2 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_GPIP_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_GPRS_PS.png b/apps/dm_new/public/images/map/layericon/UFL_GPRS_PS.png new file mode 100644 index 000000000..79c120f20 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_GPRS_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_GVAL_PS.png b/apps/dm_new/public/images/map/layericon/UFL_GVAL_PS.png new file mode 100644 index 000000000..e8f7cde2e Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_GVAL_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_KMAN_PS.png b/apps/dm_new/public/images/map/layericon/UFL_KMAN_PS.png new file mode 100644 index 000000000..764ce8ba5 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_KMAN_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_KPOL_PS.png b/apps/dm_new/public/images/map/layericon/UFL_KPOL_PS.png new file mode 100644 index 000000000..d9fa712cf Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_KPOL_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/UFL_VALV_PS.png b/apps/dm_new/public/images/map/layericon/UFL_VALV_PS.png new file mode 100644 index 000000000..1b5d70178 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/UFL_VALV_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_FIRE_PS.png b/apps/dm_new/public/images/map/layericon/WTL_FIRE_PS.png new file mode 100644 index 000000000..4137a3f74 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_FIRE_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_FLOW_PS.png b/apps/dm_new/public/images/map/layericon/WTL_FLOW_PS.png new file mode 100644 index 000000000..285f7edfa Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_FLOW_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_MANH_PS.png b/apps/dm_new/public/images/map/layericon/WTL_MANH_PS.png new file mode 100644 index 000000000..5f2a57cfe Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_MANH_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_META_PS.png b/apps/dm_new/public/images/map/layericon/WTL_META_PS.png new file mode 100644 index 000000000..22c7af31b Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_META_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_PIPE_PS.png b/apps/dm_new/public/images/map/layericon/WTL_PIPE_PS.png new file mode 100644 index 000000000..c9c6863f6 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_PIPE_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS.png b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS.png new file mode 100644 index 000000000..d7b307a61 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_BLACK.png b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_BLACK.png new file mode 100644 index 000000000..395abeb78 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_BLACK.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_GRAY.png b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_GRAY.png new file mode 100644 index 000000000..33a667a1e Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_GRAY.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_GREEN.png b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_GREEN.png new file mode 100644 index 000000000..33933b9e0 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_GREEN.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_ORANGE.png b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_ORANGE.png new file mode 100644 index 000000000..7a78c3466 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_ORANGE.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_PURPLE.png b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_PURPLE.png new file mode 100644 index 000000000..ef25607cf Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_PURPLE.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_RED.png b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_RED.png new file mode 100644 index 000000000..26fd5f68e Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_RED.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_YELLOW.png b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_YELLOW.png new file mode 100644 index 000000000..76718e865 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_RSRV_PS_YELLOW.png differ diff --git a/apps/dm_new/public/images/map/layericon/WTL_VALV_PS.png b/apps/dm_new/public/images/map/layericon/WTL_VALV_PS.png new file mode 100644 index 000000000..ca2b4788b Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/WTL_VALV_PS.png differ diff --git a/apps/dm_new/public/images/map/layericon/default.png b/apps/dm_new/public/images/map/layericon/default.png new file mode 100644 index 000000000..92bf1f587 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/default.png differ diff --git a/apps/dm_new/public/images/map/layericon/reset.png b/apps/dm_new/public/images/map/layericon/reset.png new file mode 100644 index 000000000..45f889206 Binary files /dev/null and b/apps/dm_new/public/images/map/layericon/reset.png differ diff --git a/apps/dm_new/public/images/map/toolbar/arrow_down.png b/apps/dm_new/public/images/map/toolbar/arrow_down.png new file mode 100644 index 000000000..88590ecaf Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/arrow_down.png differ diff --git a/apps/dm_new/public/images/map/toolbar/arrow_right.png b/apps/dm_new/public/images/map/toolbar/arrow_right.png new file mode 100644 index 000000000..7090c37dd Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/arrow_right.png differ diff --git a/apps/dm_new/public/images/map/toolbar/backward_icon.png b/apps/dm_new/public/images/map/toolbar/backward_icon.png new file mode 100644 index 000000000..3a853475e Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/backward_icon.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_area.png b/apps/dm_new/public/images/map/toolbar/btn_cont_area.png new file mode 100644 index 000000000..044562b55 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_area.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_area_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_area_on.png new file mode 100644 index 000000000..0129ff1bd Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_area_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_next.png b/apps/dm_new/public/images/map/toolbar/btn_cont_next.png new file mode 100644 index 000000000..075111dcf Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_next.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_next_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_next_on.png new file mode 100644 index 000000000..4fdbe3a00 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_next_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_prev.png b/apps/dm_new/public/images/map/toolbar/btn_cont_prev.png new file mode 100644 index 000000000..7e3fae7d2 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_prev.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_prev_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_prev_on.png new file mode 100644 index 000000000..fb2d55cfd Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_prev_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_print.png b/apps/dm_new/public/images/map/toolbar/btn_cont_print.png new file mode 100644 index 000000000..82596b83d Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_print.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_print_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_print_on.png new file mode 100644 index 000000000..bb7f27334 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_print_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_ruler.png b/apps/dm_new/public/images/map/toolbar/btn_cont_ruler.png new file mode 100644 index 000000000..501e460a4 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_ruler.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_ruler_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_ruler_on.png new file mode 100644 index 000000000..676a81bcc Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_ruler_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_save.png b/apps/dm_new/public/images/map/toolbar/btn_cont_save.png new file mode 100644 index 000000000..c057b9377 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_save.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_save_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_save_on.png new file mode 100644 index 000000000..bf8e6d623 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_save_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_sketch.png b/apps/dm_new/public/images/map/toolbar/btn_cont_sketch.png new file mode 100644 index 000000000..38a5f507f Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_sketch.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_sketch_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_sketch_on.png new file mode 100644 index 000000000..79fb54e03 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_sketch_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_zoomin.png b/apps/dm_new/public/images/map/toolbar/btn_cont_zoomin.png new file mode 100644 index 000000000..ac32fbab0 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_zoomin.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_zoomin_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_zoomin_on.png new file mode 100644 index 000000000..f258a965f Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_zoomin_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_zoomout.png b/apps/dm_new/public/images/map/toolbar/btn_cont_zoomout.png new file mode 100644 index 000000000..2ee0b5161 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_zoomout.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_cont_zoomout_on.png b/apps/dm_new/public/images/map/toolbar/btn_cont_zoomout_on.png new file mode 100644 index 000000000..58dcbfdae Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_cont_zoomout_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_add.png b/apps/dm_new/public/images/map/toolbar/btn_edit_add.png new file mode 100644 index 000000000..fe4f0993f Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_add.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_add_on.png b/apps/dm_new/public/images/map/toolbar/btn_edit_add_on.png new file mode 100644 index 000000000..37a836298 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_add_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_del.png b/apps/dm_new/public/images/map/toolbar/btn_edit_del.png new file mode 100644 index 000000000..3bb372ab9 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_del.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_del_on.png b/apps/dm_new/public/images/map/toolbar/btn_edit_del_on.png new file mode 100644 index 000000000..89e558739 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_del_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_next.png b/apps/dm_new/public/images/map/toolbar/btn_edit_next.png new file mode 100644 index 000000000..df4913c90 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_next.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_next_on.png b/apps/dm_new/public/images/map/toolbar/btn_edit_next_on.png new file mode 100644 index 000000000..4e5540b55 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_next_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_prev.png b/apps/dm_new/public/images/map/toolbar/btn_edit_prev.png new file mode 100644 index 000000000..e94bf6d42 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_prev.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_prev_on.png b/apps/dm_new/public/images/map/toolbar/btn_edit_prev_on.png new file mode 100644 index 000000000..8645dedfa Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_prev_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_save.png b/apps/dm_new/public/images/map/toolbar/btn_edit_save.png new file mode 100644 index 000000000..5f01dd55c Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_save.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_save_on.png b/apps/dm_new/public/images/map/toolbar/btn_edit_save_on.png new file mode 100644 index 000000000..b035687d6 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_save_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_slt.png b/apps/dm_new/public/images/map/toolbar/btn_edit_slt.png new file mode 100644 index 000000000..aaf2bbd08 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_slt.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_slt_on.png b/apps/dm_new/public/images/map/toolbar/btn_edit_slt_on.png new file mode 100644 index 000000000..02d035a74 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_slt_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_snap.png b/apps/dm_new/public/images/map/toolbar/btn_edit_snap.png new file mode 100644 index 000000000..fc91d4304 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_snap.png differ diff --git a/apps/dm_new/public/images/map/toolbar/btn_edit_snap_on.png b/apps/dm_new/public/images/map/toolbar/btn_edit_snap_on.png new file mode 100644 index 000000000..f856d8fbe Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/btn_edit_snap_on.png differ diff --git a/apps/dm_new/public/images/map/toolbar/close_icon.png b/apps/dm_new/public/images/map/toolbar/close_icon.png new file mode 100644 index 000000000..e8e76d5d7 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/close_icon.png differ diff --git a/apps/dm_new/public/images/map/toolbar/ico_gis_sprite.png b/apps/dm_new/public/images/map/toolbar/ico_gis_sprite.png new file mode 100644 index 000000000..0ee4b5985 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/ico_gis_sprite.png differ diff --git a/apps/dm_new/public/images/map/toolbar/icon-viewclose.png b/apps/dm_new/public/images/map/toolbar/icon-viewclose.png new file mode 100644 index 000000000..d93ce9c05 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/icon-viewclose.png differ diff --git a/apps/dm_new/public/images/map/toolbar/img_base_map.png b/apps/dm_new/public/images/map/toolbar/img_base_map.png new file mode 100644 index 000000000..7f96fcf5e Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/img_base_map.png differ diff --git a/apps/dm_new/public/images/map/toolbar/img_network_map.png b/apps/dm_new/public/images/map/toolbar/img_network_map.png new file mode 100644 index 000000000..df80af6dc Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/img_network_map.png differ diff --git a/apps/dm_new/public/images/map/toolbar/img_road_map.png b/apps/dm_new/public/images/map/toolbar/img_road_map.png new file mode 100644 index 000000000..02d015d12 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/img_road_map.png differ diff --git a/apps/dm_new/public/images/map/toolbar/img_settle_map.png b/apps/dm_new/public/images/map/toolbar/img_settle_map.png new file mode 100644 index 000000000..1a93f50e8 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/img_settle_map.png differ diff --git a/apps/dm_new/public/images/map/toolbar/loading.gif b/apps/dm_new/public/images/map/toolbar/loading.gif new file mode 100644 index 000000000..7c3683bb4 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/loading.gif differ diff --git a/apps/dm_new/public/images/map/toolbar/map_pin.png b/apps/dm_new/public/images/map/toolbar/map_pin.png new file mode 100644 index 000000000..b6cc2f6aa Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/map_pin.png differ diff --git a/apps/dm_new/public/images/map/toolbar/toggle_off.png b/apps/dm_new/public/images/map/toolbar/toggle_off.png new file mode 100644 index 000000000..d5dea9f67 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/toggle_off.png differ diff --git a/apps/dm_new/public/images/map/toolbar/toggle_on.png b/apps/dm_new/public/images/map/toolbar/toggle_on.png new file mode 100644 index 000000000..9cb573875 Binary files /dev/null and b/apps/dm_new/public/images/map/toolbar/toggle_on.png differ