빗물재이용 시설 작업중
This commit is contained in:
@@ -2,8 +2,6 @@
|
||||
|
||||
import "@common/assets/styles/grid.css";
|
||||
|
||||
import { ENDPOINT } from "@/shared/config/api";
|
||||
import { Button, DataTable, Input } from "@common/components";
|
||||
import { useQuery } from "@tanstack/react-query";
|
||||
import { getCoreRowModel, useReactTable } from "@tanstack/react-table";
|
||||
import { Button, DataTable, Input } from "@common/components";
|
||||
@@ -11,6 +9,8 @@ import { SiteApi, type ISite, type ISiteParams } from "@/entities/site";
|
||||
import { ENDPOINT } from "@/shared/config";
|
||||
import { PageLayout } from "@/shared/ui/page-layout";
|
||||
import { columns } from "../model/table-columns";
|
||||
import { useRouter } from "next/navigation";
|
||||
import { useEffect, useState } from "react";
|
||||
|
||||
function SitePage() {
|
||||
const router = useRouter();
|
||||
|
||||
@@ -1,52 +0,0 @@
|
||||
'use client'
|
||||
|
||||
import { ScrollArea, SearchDiv, SelectBox, UiTable } from '@common/business_components';
|
||||
import { Button } from '@common/components';
|
||||
import { PublicReuseFaciltyFormInsert } from '../../../../components/ui/publicReuseInsertForm';
|
||||
import { useWrStore } from '../../../store';
|
||||
|
||||
|
||||
|
||||
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 (
|
||||
<h1 className="pl-3 text-xl">○공공 하수처리시설 등록</h1>
|
||||
)
|
||||
}
|
||||
const onSelectValue = (val: string) => {
|
||||
console.log(val)
|
||||
}
|
||||
return (
|
||||
<>
|
||||
<div className="grid grid-cols-2 gap-4 h-full">
|
||||
<div className='col-span-4'>
|
||||
<h1 className="pl-3 text-xl" > 하수재이용시설 등록</h1>
|
||||
<div className="m-8">
|
||||
<SearchDiv>
|
||||
<div className='w-4/5 grid grid-cols-12 gap-1 mx-4'>
|
||||
<SelectBox className='col-span-4' label={searchDiv} selectArray={selectBox} onSelectValue={onSelectValue} />
|
||||
</div>
|
||||
<div className='w-1/5 flex items-center justify-end'>
|
||||
<Button className='mr-4 rounded-lg'>조회</Button>
|
||||
<Button className='mr-4 rounded-lg'>신규추가</Button>
|
||||
</div>
|
||||
</SearchDiv>
|
||||
</div>
|
||||
</div>
|
||||
<div className="col-span-1 pl-11">
|
||||
<UiTable tableData={publicReuseFacilityData} headlist={pubFacHeadList} pageSize={100} total={10} headName={headName()} children={undefined}/>
|
||||
</div>
|
||||
<div className="col-span-1 pr-6 max-h-full overflow-y-scroll">
|
||||
<ScrollArea>
|
||||
<PublicReuseFaciltyFormInsert />
|
||||
{/* <ScrollBar orientation="vertical"></ScrollBar> */}
|
||||
</ScrollArea>
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
)
|
||||
}
|
||||
@@ -4,7 +4,7 @@ import type { bdstType, rainRuseType, TableUpperProps } from "@/app/store/ruseFc
|
||||
import { BdstReg } from "@/components/ui/form/fcltReg/bdstReg/bdstRegForm";
|
||||
import { RainRegForm } from "@/components/ui/form/fcltReg/rainReg/component";
|
||||
import { BdstRegModal } from "@/components/ui/modal/bdstReg/component";
|
||||
import { ScrollArea, SearchDiv, SearchInput, UiTable } from "@common/business_components";
|
||||
import { ScrollArea, SearchDiv, SearchInput, UiModal, UiTable } from "@common/business_components";
|
||||
import { Button, TableHead, TableRow } from "@common/components";
|
||||
import { useEffect, useState } from "react";
|
||||
|
||||
@@ -56,7 +56,7 @@ export default function Home() {
|
||||
setbdstTable(table)
|
||||
}
|
||||
}, [code,bdstObj]);
|
||||
const cellClick=(val:number)=>{
|
||||
const cellClick: (val: number | undefined) => void = (val) => {
|
||||
|
||||
let data
|
||||
if((bdstTable ?? []).length > 0) {
|
||||
@@ -64,15 +64,7 @@ export default function Home() {
|
||||
setRinBdstForm(data)
|
||||
}
|
||||
}
|
||||
const divTest =()=>{
|
||||
return(
|
||||
<>
|
||||
|
||||
<BdstReg />
|
||||
</>
|
||||
|
||||
)
|
||||
}
|
||||
|
||||
return (
|
||||
<>
|
||||
@@ -82,11 +74,13 @@ export default function Home() {
|
||||
<div className="m-8">
|
||||
<SearchDiv >
|
||||
<div className='w-4/5 grid grid-cols-12 gap-1 mx-4'>
|
||||
<SearchInput className='col-span-3 my-7' label="건물명" />
|
||||
<SearchInput className='col-span-3 my-7' label="건물명" textValue={""} setText={function (val: string): void {
|
||||
throw new Error("Function not implemented.");
|
||||
} } />
|
||||
</div>
|
||||
<div className='w-1/5 flex items-center justify-end'>
|
||||
<Button className='mr-4 rounded-lg'>조회</Button>
|
||||
<BdstRegModal butNm="신규등록" title='건축물 시설 등록(빗물이용시설)' body={<BdstReg></BdstReg>} />
|
||||
<UiModal butNm="신규등록" title='건축물 시설 등록(빗물이용시설)' body={<BdstReg></BdstReg>} bodyClass="sm:max-w-7xl" />
|
||||
{/* <Button className='mr-4 rounded-lg' onClick={()=>bdstRegModal('ㅁ',divTest())}>신규등록</Button> */}
|
||||
</div>
|
||||
</SearchDiv>
|
||||
|
||||
@@ -158,7 +158,6 @@ export function RainRegForm({data}:{data:rainRuseType[]} ) {
|
||||
onSelectValue(val);
|
||||
}}
|
||||
value={field.value}
|
||||
defaultValue={field.value}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
@@ -258,7 +257,7 @@ export function RainRegForm({data}:{data:rainRuseType[]} ) {
|
||||
label={""}
|
||||
selectArray={rain.selectYN}
|
||||
onSelectValue={onSelectValue}
|
||||
{...field}
|
||||
value={field.value}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
@@ -298,7 +297,7 @@ export function RainRegForm({data}:{data:rainRuseType[]} ) {
|
||||
label={""}
|
||||
selectArray={rain.selectYN}
|
||||
onSelectValue={onSelectValue}
|
||||
{...field}
|
||||
value={field.value}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user