diff --git a/apps/wr/app/page.tsx b/apps/wr/app/page.tsx
index 0564641f6..385cfb9e8 100644
--- a/apps/wr/app/page.tsx
+++ b/apps/wr/app/page.tsx
@@ -1,26 +1,27 @@
-import Link from 'next/link';
-import { Button } from '@common/components/ui';
-
-
+import Link from "next/link";
+import { Button } from "@common/components/ui";
export default function Home() {
return (
<>
-
-
-
-
+
+
+
+
-
+
+
- >
+ >
);
}
diff --git a/apps/wr/app/ruseFcltMng/fcltReg/htdflReg/page.jsx b/apps/wr/app/ruseFcltMng/fcltReg/htdflReg/page.jsx
new file mode 100644
index 000000000..aa3c521d8
--- /dev/null
+++ b/apps/wr/app/ruseFcltMng/fcltReg/htdflReg/page.jsx
@@ -0,0 +1,64 @@
+"use client";
+
+import { useWrStore } from "@/app/store";
+import {
+ ScrollArea,
+ SearchDiv,
+ SearchInput,
+ UiTable,
+} from "@common/business_components";
+import { Button } from "@common/components";
+import { headMakeColSpan } from "../rainReg/page";
+import { HtdflRegForm } from "@/components/ui/form/fcltReg/htdflReg/component";
+
+export default function Home() {
+ const { htdfl } = useWrStore((state) => state);
+ const nodeList = headMakeColSpan(htdfl.upHeadList);
+
+ const headName = () => {
+ return (
+ <>
+
○건축물 목록
+ >
+ );
+ };
+
+ return (
+ <>
+
+
+
온배수시설 등록
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {nodeList}
+
+
+
+
+
+
+
+
+ >
+ );
+}
diff --git a/apps/wr/app/ruseFcltMng/fcltReg/pbnstReg/page.tsx b/apps/wr/app/ruseFcltMng/fcltReg/pbnstReg/page.tsx
index 3daba7ab6..e98ef70b3 100644
--- a/apps/wr/app/ruseFcltMng/fcltReg/pbnstReg/page.tsx
+++ b/apps/wr/app/ruseFcltMng/fcltReg/pbnstReg/page.tsx
@@ -1,52 +1,90 @@
-'use client'
+"use client";
-import { ScrollArea, SearchDiv, SelectBox, UiTable } from '@common/business_components';
-import { Button } from '@common/components';
-import { useWrStore } from '../../../store';
-import { PbnstRegForm } from '@/components/ui/form/fcltReg/pbnstReg/component';
+import {
+ ScrollArea,
+ SearchDiv,
+ SelectBox,
+ UiTable,
+} from "@common/business_components";
+import { Button } from "@common/components";
+import { useWrStore } from "../../../store";
+import { PbnstBuseForm } from "@/components/ui/form/fcltReg/pbnstReg/buseReg/component";
+import { Tabs, TabsList, TabsTrigger, TabsContent } from "@common/components";
+import { PbnstMngForm} from "@/components/ui/form/fcltReg/pbnstReg/mngReg/component";
-
- export default function PublicReuseFaciltyInsert() {
- const {pubFac} = useWrStore((state) => state);
- const { pubFacHeadList, publicReuseFacilityData} = pubFac;
- const searchDiv = '하수재이용시설 '
- const selectBox = [{ text: '서울하수처리시설', val: "1_hasu" }, { text: '서울1하수처리시설', val: "2_hasu" }, { text: '서울2하수처리시설', val: "3_hasu" }]
+export default function PublicReuseFaciltyInsert() {
+ const { pubFac } = useWrStore((state) => state);
+ const { pubFacHeadList, publicReuseFacilityData } = pubFac;
+ const searchDiv = "하수재이용시설 ";
+ const selectBox = [
+ { text: "서울하수처리시설", val: "1_hasu" },
+ { text: "서울1하수처리시설", val: "2_hasu" },
+ { text: "서울2하수처리시설", val: "3_hasu" },
+ ];
const headName = () => {
- return (
-
○공공 하수처리시설 등록
- )
- }
+ return
○공공 하수처리시설 등록
;
+ };
const onSelectValue = (val: string) => {
- console.log(val)
- }
+ console.log(val);
+ };
return (
<>
-
-
하수재이용시설 등록
+
+
하수재이용시설 등록
-
-
-
+
+
-
-
-
- {/* */}
-
+
+
+
+
+
+
+ 운영정보
+ 시설현황
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
>
- )
-}
\ No newline at end of file
+ );
+}
diff --git a/apps/wr/app/store/ruseFcltMng/fcltReg/htdflReg/index.tsx b/apps/wr/app/store/ruseFcltMng/fcltReg/htdflReg/index.tsx
new file mode 100644
index 000000000..fcd8b02ba
--- /dev/null
+++ b/apps/wr/app/store/ruseFcltMng/fcltReg/htdflReg/index.tsx
@@ -0,0 +1,89 @@
+import {
+ upHeadList,
+ type rainFacOfType,
+ type TableUpperProps,
+} from "../rainReg";
+
+const htdflOfObject: rainFacOfType[] = [
+ {
+ sido: "서울",
+ sigungo: "종로구",
+ facilityName: "그랑서울",
+ location: "종로 33",
+ locationgubun: "업무시설",
+ firstConstructionPermission: "2024-10-10",
+ buildingArea: "50",
+ facilityCapacity: "800,000",
+ reuse: "Y",
+ permissionDay: "2024-10-10",
+ register: "Y",
+ legalTargetYn: "Y",
+ },
+ {
+ sido: "서울",
+ sigungo: "종로구",
+ facilityName: "그랑서울",
+ location: "종로 33",
+ locationgubun: "업무시설",
+ firstConstructionPermission: "2024-10-10",
+ buildingArea: "50",
+ facilityCapacity: "800,000",
+ reuse: "Y",
+ permissionDay: "2024-10-10",
+ register: "Y",
+ legalTargetYn: "Y",
+ },
+ {
+ sido: "서울",
+ sigungo: "종로구",
+ facilityName: "그랑서울",
+ location: "종로 33",
+ locationgubun: "업무시설",
+ firstConstructionPermission: "2024-10-10",
+ buildingArea: "50",
+ facilityCapacity: "800,000",
+ reuse: "Y",
+ permissionDay: "2024-10-10",
+ register: "Y",
+ legalTargetYn: "Y",
+ },
+];
+
+export type htdflFacState = {
+ htdfl: {
+ isInit: boolean;
+ upHeadList: TableUpperProps[];
+ htdflOfObject: rainFacOfType[];
+ };
+};
+type htdflFacSActions = {
+ decrementList: () => void;
+};
+
+export type htdflFacType = htdflFacState & htdflFacSActions;
+
+export const htdflFacStateExport: htdflFacState = {
+ htdfl: {
+ isInit: false,
+ upHeadList: upHeadList,
+ htdflOfObject: htdflOfObject,
+ },
+};
+export const htdflFacActionsExport: (set: any) => htdflFacSActions = (
+ set: any
+) => {
+ return {
+ decrementList: () =>
+ set((state: htdflFacState) => {
+ return {
+ htdfl: {
+ upHeadList: state.htdfl.upHeadList,
+ rainOfObject: state.htdfl.htdflOfObject.slice(
+ 0,
+ state.htdfl.htdflOfObject.length - 1
+ ),
+ },
+ };
+ }),
+ };
+};
diff --git a/apps/wr/app/store/store.tsx b/apps/wr/app/store/store.tsx
index e2b8b807a..51a4dfef8 100644
--- a/apps/wr/app/store/store.tsx
+++ b/apps/wr/app/store/store.tsx
@@ -1,25 +1,61 @@
-import { createStore } from 'zustand/vanilla';
-import { pubFacActionsExport, pubFacStateExport, type pubFacState } from './ruseFcltMng/fcltReg/pbnstReg';
-import { rainFacActionsExport, rainFacStateExport, type rainFacState, type rainFacType } from './ruseFcltMng/fcltReg/rainReg';
-import { rswtFacActionsExport, rswtFacStateExport, type rswtFacState, type rswtFacType } from './ruseFcltMng/fcltReg/rswtReg';
-import { matDmdActionsExport, matDmdStateExport, type matDmdState, type matDmdType } from './matDmd';
+import { createStore } from "zustand/vanilla";
+import {
+ pubFacActionsExport,
+ pubFacStateExport,
+ type pubFacState,
+} from "./ruseFcltMng/fcltReg/pbnstReg";
+import {
+ rainFacActionsExport,
+ rainFacStateExport,
+ type rainFacState,
+ type rainFacType,
+} from "./ruseFcltMng/fcltReg/rainReg";
+import {
+ rswtFacActionsExport,
+ rswtFacStateExport,
+ type rswtFacState,
+ type rswtFacType,
+} from "./ruseFcltMng/fcltReg/rswtReg";
+import {
+ matDmdActionsExport,
+ matDmdStateExport,
+ type matDmdState,
+ type matDmdType,
+} from "./matDmd";
+import {
+ htdflFacActionsExport,
+ htdflFacStateExport,
+ type htdflFacState,
+ type htdflFacType,
+} from "./ruseFcltMng/fcltReg/htdflReg";
-
-export type WrStore = pubFacState & rainFacType &rswtFacType &matDmdType;
-export const StoreZus = (initState: rainFacState& pubFacState & rswtFacState &matDmdState= {
- ...pubFacStateExport,
- ...rainFacStateExport,
- ...rswtFacStateExport ,
- ...matDmdStateExport
-}) => {
+export type WrStore = pubFacState &
+ rainFacType &
+ rswtFacType &
+ matDmdType &
+ htdflFacType;
+export const StoreZus = (
+ initState: rainFacState &
+ pubFacState &
+ rswtFacState &
+ matDmdState &
+ htdflFacState = {
+ ...pubFacStateExport,
+ ...rainFacStateExport,
+ ...rswtFacStateExport,
+ ...matDmdStateExport,
+ ...htdflFacStateExport,
+ }
+) => {
return createStore()((set) => {
return {
...initState,
...pubFacActionsExport(set),
...rainFacActionsExport(set),
...rswtFacActionsExport(set),
- ...matDmdActionsExport(set)
- }
- })
-}
-//store 등록하는 부분
\ No newline at end of file
+ ...matDmdActionsExport(set),
+ ...htdflFacActionsExport(set),
+ };
+ });
+};
+//store 등록하는 부분
diff --git a/apps/wr/components/ui/form/fcltReg/htdflReg/component.tsx b/apps/wr/components/ui/form/fcltReg/htdflReg/component.tsx
new file mode 100644
index 000000000..4efff1a39
--- /dev/null
+++ b/apps/wr/components/ui/form/fcltReg/htdflReg/component.tsx
@@ -0,0 +1,469 @@
+"use client";
+
+import {
+ Form,
+ FormField,
+ FormUi,
+ SelectBox,
+} from "@common/business_components/ui";
+import { Input } from "@common/components/ui";
+import { zodResolver } from "@hookform/resolvers/zod";
+import { useForm } from "react-hook-form";
+import { z } from "zod";
+import { useWrStore } from "@/app/store";
+import { selectClass } from "@/app/store/ruseFcltMng/fcltReg/rainReg";
+
+const formSchema = z.object({
+ etgtType: z.string().min(2).max(50),
+ fclCpct: z.string(),
+ plwtYn: z.string(),
+ orgwtwtritspt: z.string(),
+ orgwtocrnprocs: z.string(),
+ wtritentrctp: z.string(),
+ amtgnr: z.string(),
+ prcsfcltcpct: z.string(),
+ utztnqnt: z.string(),
+ utztnusgcd: z.string(),
+wntUntprc: z.string().min(1),
+ grssClfg: z.string().min(1),
+ tn: z.string().min(1).optional(),
+ combResdch: z.string().min(1).optional(),
+ tp: z.string().min(1).optional(),
+ trbt: z.string().min(1).optional(),
+ ph: z.string().min(1).optional(),
+ bod: z.string().min(1).optional(),
+ clIonQnt: z.string().min(1).optional(),
+ smll: z.string().min(1).optional(),
+ cdtnv: z.string().min(1).optional(),
+ crmty: z.string().min(1).optional(),
+ emsnexittp: z.string(),
+});
+
+export function HtdflRegForm() {
+ const { rswt } = useWrStore((state) => state);
+
+ const form = useForm>({
+ resolver: zodResolver(formSchema),
+ defaultValues: {
+ etgtType: "",
+ fclCpct: "",
+ plwtYn: "",
+ orgwtwtritspt: "",
+ orgwtocrnprocs: "",
+ wtritentrctp: "",
+ amtgnr: "",
+ prcsfcltcpct: "",
+ utztnqnt: "",
+ utztnusgcd: "",
+ wntUntprc: "",
+ grssClfg: "",
+ tn: "",
+ combResdch: "",
+ tp: "",
+ trbt: "",
+ ph: "",
+ bod: "",
+ clIonQnt: "",
+ smll: "",
+ cdtnv: "",
+ crmty: "",
+ emsnexittp: "",
+ },
+ });
+
+ // 2. Define a submit handler.
+ function onSubmit(values: z.infer) {
+ // Do something with the form values.
+ // ✅ This will be type-safe and validated.
+ console.log(values);
+ }
+
+ const onSelectValue = (val: string) => {
+ console.log(val);
+ };
+ return (
+