빌드 확인필요
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import { numSize, txtSize } from "@/app/store/common/code/basicCode";
|
||||
import type { TableUpperProps } from "@/app/store/common/type/header";
|
||||
import type { chHeadType } from "@/app/store/prfmncReg/chkgdnReg/rainChkgdn/headList";
|
||||
|
||||
@@ -14,7 +15,12 @@ export const pubFacHeadListExport: TableUpperProps[] = [
|
||||
|
||||
export const pbnstMngUpHeadListExport: TableUpperProps[] = [
|
||||
{ id: "choose", title: "선택", type: "checkbox" },
|
||||
{ id: "operMthd", title: "운영방식",type: "select", selectData: "ruseMngMtd" },
|
||||
{
|
||||
id: "operMthd",
|
||||
title: "운영방식",
|
||||
type: "select",
|
||||
selectData: "ruseMngMtd",
|
||||
},
|
||||
{ id: "rprtvBzenty", title: "대행업체", edit: true, maxLength: 10 },
|
||||
{
|
||||
id: "bgngDt",
|
||||
@@ -47,7 +53,7 @@ export const pbnstDemandHeadListExport: TableUpperProps[] = [
|
||||
|
||||
export const pbnstOrgwtHeadListRxport: TableUpperProps[] = [
|
||||
{ id: "ruseUtztnFcltNm", title: "하수처리장명" },
|
||||
{ id: "orgwtWtritQnt", title: "원수취수량" , type:'number'},
|
||||
{ id: "orgwtWtritQnt", title: "원수취수량", type: "number" },
|
||||
{ id: "tmsYn", title: "하수처리량TMS 전후" },
|
||||
{ id: "dschgFmYn", title: "하수처리장 방류 유량계 전·후" },
|
||||
{ id: "dtlPstnExpln", title: "상세위치", edit: true },
|
||||
@@ -60,7 +66,6 @@ export const fcOrgwtsHeadListExport: TableUpperProps[] = [
|
||||
{ id: "addr", title: "위치" },
|
||||
];
|
||||
|
||||
|
||||
export const pbnstMngNmExport: chHeadType[] = [
|
||||
{ headNm: "upChangeRe", text: "운영대행기간", length: 2 },
|
||||
];
|
||||
@@ -69,65 +74,91 @@ export type formDetailType = {
|
||||
id: string;
|
||||
lable: string;
|
||||
type?: string;
|
||||
maxLenght?: number;
|
||||
selectData?: string; // select box일 경우
|
||||
option?:string
|
||||
option?: string;
|
||||
};
|
||||
|
||||
export const wasteWaterFcltINfo: formDetailType[] = [
|
||||
{ id: "wwtEmsnFcltPrmsnYn", lable: "폐수배출물신고 허가여부", type: "select" , selectData: "yn"},
|
||||
{
|
||||
id: "wwtEmsnFcltPrmsnYn",
|
||||
lable: "폐수배출물신고 허가여부",
|
||||
type: "select",
|
||||
selectData: "yn",
|
||||
},
|
||||
{ id: "tmsInstlYn", lable: "Tms설치여부", type: "select", selectData: "yn" },
|
||||
{ id: "pbnstDrngInflwExclYn", lable: "공공하수도유입제외 허가여부", type: "select" , selectData: "yn" },
|
||||
{
|
||||
id: "pbnstDrngInflwExclYn",
|
||||
lable: "공공하수도유입제외 허가여부",
|
||||
type: "select",
|
||||
selectData: "yn",
|
||||
},
|
||||
];
|
||||
|
||||
export const concentratedWaterInfo: formDetailType[] = [
|
||||
{ id: "erctWtrOcrnCpct", lable: "눙축수 발생량(m³/일)", type: "number" },
|
||||
{ id: "erctUswtrLinkSpt", lable: "눙축수연계지점" },
|
||||
{ id: "erctUswtrFcltCpct", lable: "시설용량(m³/일)", type: "number" },
|
||||
{ id: "erctUswtrPrcsMeth", lable: "눙축수처리방식", type : "select", selectData: "erctUswtrPrcsMeth" },
|
||||
{ id: "erctUswtrPrcsMsrcCd", lable: "눙축수처리공법" },
|
||||
{ id: "erctWtrOcrnCpct", lable: "눙축수 발생량(m³/일)", type: "number",maxLenght:numSize },
|
||||
{ id: "erctUswtrLinkSpt", lable: "눙축수연계지점", maxLenght:txtSize },
|
||||
{ id: "erctUswtrFcltCpct", lable: "시설용량(m³/일)", type: "number" ,maxLenght:numSize },
|
||||
{
|
||||
id: "erctUswtrPrcsMeth",
|
||||
lable: "눙축수처리방식",
|
||||
type: "select",
|
||||
selectData: "erctUswtrPrcsMeth",
|
||||
},
|
||||
{ id: "erctUswtrPrcsMsrcCd", lable: "눙축수처리공법" ,maxLenght:txtSize},
|
||||
];
|
||||
|
||||
export const ruseFcltinfo: formDetailType[] = [
|
||||
{ id: "rprcsFcltCpct", lable: "시설용량(m³/일)", type: "number" },
|
||||
{ id: "majorPrcsMsrcCd", lable: "주처리공법" },
|
||||
{ id: "addr", lable: "위치(주소)" },
|
||||
{ id: "rprcsMthdCd", lable: "재처리방식", type: "select", selectData: "rusePrcsMthdCd" },
|
||||
{ id: "inoutYn", lable: "위치(처리장 내외)" ,type: "select" , selectData: "yn"}, // 머가 내? 외?,
|
||||
{ id: "mainSplyPumpCpct", lable: "메인공급펌프 용량", type: "number" },
|
||||
{ id: "rprcsFcltCpct", lable: "시설용량(m³/일)", type: "number", maxLenght:numSize },
|
||||
{ id: "majorPrcsMsrcCd", lable: "주처리공법", maxLenght:txtSize },
|
||||
{ id: "addr", lable: "위치(주소)", maxLenght:txtSize},
|
||||
{
|
||||
id: "rprcsMthdCd",
|
||||
lable: "재처리방식",
|
||||
type: "select",
|
||||
selectData: "rusePrcsMthdCd",
|
||||
|
||||
},
|
||||
{
|
||||
id: "inoutYn",
|
||||
lable: "위치(처리장 내외)",
|
||||
type: "select",
|
||||
selectData: "yn",
|
||||
}, // 머가 내? 외?,
|
||||
{ id: "mainSplyPumpCpct", lable: "메인공급펌프 용량", type: "number" , maxLenght:numSize},
|
||||
];
|
||||
|
||||
export const businessMoneyInfo: formDetailType[] = [
|
||||
{ id: "gvsbs", lable: "국고", type: "number" },
|
||||
{ id: "lcep", lable: "지방비", type: "number" },
|
||||
{ id: "cusrAlotm", lable: "민간투자비", type: "number" },
|
||||
{ id: "etc", lable: "기타" },
|
||||
{ id: "gvsbs", lable: "국고", type: "number" , maxLenght:numSize},
|
||||
{ id: "lcep", lable: "지방비", type: "number" , maxLenght:numSize},
|
||||
{ id: "cusrAlotm", lable: "민간투자비", type: "number" , maxLenght:numSize},
|
||||
{ id: "etc", lable: "기타" , maxLenght:numSize},
|
||||
{ id: "totalMoney", lable: "합계", type: "number", option: "disabled" },
|
||||
];
|
||||
|
||||
export const businessSttnInfo: formDetailType[] = [
|
||||
{ id: "seCd", lable: "구분", type: "select", selectData: "ruseSeCd" },
|
||||
{ id: "bizMthdCd", lable: "사업방식", type: "select", selectData: "ruseBizMthdCd" },
|
||||
{
|
||||
id: "bizMthdCd",
|
||||
lable: "사업방식",
|
||||
type: "select",
|
||||
selectData: "ruseBizMthdCd",
|
||||
},
|
||||
{ id: "bizCmcnDay", lable: "사업준공일", type: "date" },
|
||||
{ id: "instlAprvSncnDt", lable: "설치승인인가일", type: "date" },
|
||||
];
|
||||
|
||||
export const ruseFcltIntakeList: formDetailType[] = [
|
||||
{ id: "seCd", lable: "구분" },
|
||||
{ id: "bizMthdCd", lable: "사업방식" },
|
||||
{ id: "bizCmcnDay", lable: "사업준공일", type: "date" },
|
||||
{ id: "instlAprvSncnDt", lable: "설치승인인가일", type: "date" },
|
||||
];
|
||||
|
||||
export const ruseWaterQulityList: formDetailType[] = [
|
||||
{ id: "bod", lable: "BOD(mg/L)", type: "text" },
|
||||
{ id: "grssClfg", lable: "총대장균군수(개/mg)", type: "text" },
|
||||
{ id: "combResdch", lable: "결합잔류염소(mh/L)", type: "text" },
|
||||
{ id: "trbt", lable: "탁도(NTU)", type: "text" },
|
||||
{ id: "smll", lable: "냄새", type: "text" },
|
||||
{ id: "crmty", lable: "색도", type: "text" },
|
||||
{ id: "tn", lable: "총질소(mg/L)", type: "text" },
|
||||
{ id: "tph", lable: "총인(mg/L)", type: "text" },
|
||||
{ id: "ph", lable: "수소이온농도", type: "text" },
|
||||
{ id: "clIonQnt", lable: "염화물(mg/L)", type: "text" },
|
||||
{ id: "cdtnv", lable: "전기전도도(μs/cm)", type: "text" },
|
||||
{ id: "bod", lable: "BOD(mg/L)", type: "text", maxLenght:numSize },
|
||||
{ id: "grssClfg", lable: "총대장균군수(개/mg)", type: "text" , maxLenght:numSize},
|
||||
{ id: "combResdch", lable: "결합잔류염소(mh/L)", type: "text" , maxLenght:numSize},
|
||||
{ id: "trbt", lable: "탁도(NTU)", type: "text" , maxLenght:numSize},
|
||||
{ id: "smll", lable: "냄새", type: "text", maxLenght:numSize },
|
||||
{ id: "crmty", lable: "색도", type: "text", maxLenght:numSize },
|
||||
{ id: "tn", lable: "총질소(mg/L)", type: "text", maxLenght:numSize },
|
||||
{ id: "tph", lable: "총인(mg/L)", type: "text" , maxLenght:numSize},
|
||||
{ id: "ph", lable: "수소이온농도", type: "text", maxLenght:numSize},
|
||||
{ id: "clIonQnt", lable: "염화물(mg/L)", type: "text", maxLenght:numSize },
|
||||
{ id: "cdtnv", lable: "전기전도도(μs/cm)", type: "text", maxLenght:numSize },
|
||||
];
|
||||
|
||||
@@ -38,6 +38,7 @@ import SdmInsertForm from "@common/business_components/ui/sdmInsertForm";
|
||||
import type { DemandCompType } from "@common/business_components/ui/sdmInsertForm/form";
|
||||
import RuseMngTableForm from "@/components/ui/table/pbnstReg/ruseMngTableForm/ruseMngTableForm";
|
||||
import type { SelectDataType } from "@common/business_components";
|
||||
import { BuseWaterQulity } from "./buseWaterQulity/buseWaterQulity";
|
||||
|
||||
export function PbnstBuseForm({
|
||||
indexMng = 0,
|
||||
@@ -474,7 +475,7 @@ export function PbnstBuseForm({
|
||||
/>
|
||||
</div>
|
||||
|
||||
<MngRegFormDetail
|
||||
{/* <MngRegFormDetail
|
||||
formList={ruseWaterQulityList}
|
||||
h1Title={`하수처리수 재이용시설 보증수질 `}
|
||||
subTitle="※재처리시설이 있는 경우만 작성"
|
||||
@@ -483,7 +484,21 @@ export function PbnstBuseForm({
|
||||
sonClass="col-span-4"
|
||||
indexMng={indexMng}
|
||||
indexBiz={indexBiz}
|
||||
/> */}
|
||||
<div>
|
||||
|
||||
<BuseWaterQulity
|
||||
h1Title={`하수처리수 재이용시설 보증수질 `}
|
||||
subTitle="※재처리시설이 있는 경우만 작성"
|
||||
form={form}
|
||||
moClass="grid grid-cols-12 gap-4"
|
||||
sonClass="col-span-4"
|
||||
indexMng={indexMng}
|
||||
indexBiz={indexBiz}
|
||||
formType={""}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div key={"hasu"}>
|
||||
<h1 className={formH1Class}>
|
||||
{"하수처리수 재이용수 수요처"}
|
||||
|
||||
+416
@@ -0,0 +1,416 @@
|
||||
import { txtSize } from "@/app/store/common/code/basicCode";
|
||||
import type { PbnstRegArrrayType } from "@/app/store/ruseFcltMng/fcltReg/pbnstReg/type";
|
||||
import { formH1Class } from "@/components/lib/class/comClass";
|
||||
import { FormField, FormUi } from "@common/business_components/ui";
|
||||
import { Input, Label } from "@common/components/ui";
|
||||
import { useCallback, useEffect, useState } from "react";
|
||||
import type { UseFormReturn } from "react-hook-form";
|
||||
|
||||
export function BuseWaterQulity({
|
||||
form,
|
||||
h1Title,
|
||||
subTitle,
|
||||
moClass,
|
||||
sonClass,
|
||||
indexMng,
|
||||
indexBiz,
|
||||
formType,
|
||||
}: {
|
||||
form: UseFormReturn<{ items: PbnstRegArrrayType }>;
|
||||
h1Title: string;
|
||||
subTitle: string;
|
||||
moClass: string;
|
||||
sonClass: string;
|
||||
indexMng: number;
|
||||
indexBiz: number;
|
||||
formType?: string;
|
||||
}) {
|
||||
const [frontPHdata, setFrontPHdata] = useState("0");
|
||||
const [backPHdata, setBackPHdata] = useState("0");
|
||||
const [chekcPk, setCheakPk] = useState("");
|
||||
|
||||
// const watchPH = useWatch({
|
||||
// name: `items.${indexMng}.fcBizs.${indexBiz}.ph`,
|
||||
// control: form.control, // useForm에서 받은 control 전달
|
||||
// });
|
||||
|
||||
useEffect(() => {
|
||||
const watchPH = form.getValues(`items.${indexMng}.fcBizs.${indexBiz}.ph`);
|
||||
const checkPkAndCycle =
|
||||
form.getValues(`items.${indexMng}.pbnstRuseFcltId`) +
|
||||
String(form.getValues(`items.${indexMng}.fcBizs.${indexBiz}.cycl`));
|
||||
|
||||
console.log('checkPkAndCycle ', checkPkAndCycle)
|
||||
if (chekcPk !== checkPkAndCycle) {
|
||||
if (watchPH && watchPH !== undefined) {
|
||||
const [frontPH, backPH] = watchPH.split("~");
|
||||
if (frontPH) {
|
||||
setFrontPHdata(frontPH);
|
||||
}
|
||||
if (backPH) {
|
||||
setBackPHdata(backPH);
|
||||
}
|
||||
} else {
|
||||
setFrontPHdata("0");
|
||||
setBackPHdata("0");
|
||||
}
|
||||
setCheakPk(checkPkAndCycle);
|
||||
}
|
||||
}, [form.getValues(`items.${indexMng}.fcBizs.${indexBiz}.ph`),
|
||||
|
||||
chekcPk]);
|
||||
|
||||
const isSetFrontPh = useCallback(
|
||||
(frontPHdata: string) => {
|
||||
if (frontPHdata && frontPHdata.length > 0) {
|
||||
const PHdata = form.getValues(
|
||||
`items.${indexMng}.fcBizs.${indexBiz}.ph`
|
||||
);
|
||||
if (PHdata) {
|
||||
const backPH = PHdata.split("~")[1];
|
||||
const MatchData = frontPHdata + "~" + backPH;
|
||||
form.setValue(`items.${indexMng}.fcBizs.${indexBiz}.ph`, MatchData);
|
||||
setFrontPHdata(frontPHdata);
|
||||
}else{
|
||||
const MatchData = frontPHdata+ "~" + '0';
|
||||
form.setValue(`items.${indexMng}.fcBizs.${indexBiz}.ph`, MatchData);
|
||||
setFrontPHdata(frontPHdata);
|
||||
|
||||
}
|
||||
}
|
||||
},
|
||||
[frontPHdata, form, indexMng, indexBiz]
|
||||
);
|
||||
|
||||
const isSetBackPh = useCallback(
|
||||
(backPHdata: string) => {
|
||||
if (backPHdata && backPHdata.length > 0) {
|
||||
const PHdata = form.getValues(
|
||||
`items.${indexMng}.fcBizs.${indexBiz}.ph`
|
||||
);
|
||||
|
||||
if (PHdata) {
|
||||
const frontPH = PHdata.split("~")[0];
|
||||
const MatchData = frontPH + "~" + backPHdata
|
||||
|
||||
console.log(' backPHdata ', MatchData)
|
||||
form.setValue(`items.${indexMng}.fcBizs.${indexBiz}.ph`, MatchData);
|
||||
setBackPHdata(backPHdata);
|
||||
}else{
|
||||
const MatchData = '0' + "~" + backPHdata;
|
||||
|
||||
form.setValue(`items.${indexMng}.fcBizs.${indexBiz}.ph`, MatchData);
|
||||
setBackPHdata(backPHdata);
|
||||
}
|
||||
}
|
||||
},
|
||||
[backPHdata, form, indexMng, indexBiz]
|
||||
);
|
||||
|
||||
return (
|
||||
<>
|
||||
{h1Title ? <h1 className={formH1Class}>{h1Title}</h1> : <></>}
|
||||
{subTitle ? <h3 className={"items-center"}>{subTitle}</h3> : <></>}
|
||||
|
||||
<div className={moClass}>
|
||||
<div className={sonClass}>
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.bod`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.bod-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="BOD(mg/L)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
const inputValue = e.target.value.replace(/[^0-9.]/g, ""); // 숫자만 저장
|
||||
field.onChange(inputValue);
|
||||
}}
|
||||
value={
|
||||
field.value !== undefined && field.value !== ""
|
||||
? `${field.value} 이하`
|
||||
: ""
|
||||
}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
<div className={sonClass}>
|
||||
{
|
||||
//TODO 불검춣확인필요
|
||||
}
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.grssClfg`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.grssClfg-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="총대장균군수(개/mg)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
field.onChange(String(e.target.value));
|
||||
}}
|
||||
value={field.value ?? ""}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
<div className={sonClass}>
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.combResdch`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.combResdch-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="결합잔류염소(mh/L)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
const inputValue = e.target.value.replace(/[^0-9.]/g, ""); // 숫자만 저장
|
||||
field.onChange(inputValue);
|
||||
}}
|
||||
value={
|
||||
field.value !== undefined && field.value !== ""
|
||||
? `${field.value} 이상`
|
||||
: ""
|
||||
}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
<div className={sonClass}>
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.trbt`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.trbt-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="탁도(NTU)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
const inputValue = e.target.value.replace(/[^0-9.]/g, ""); // 숫자만 저장
|
||||
field.onChange(inputValue);
|
||||
}}
|
||||
value={
|
||||
field.value !== undefined && field.value !== ""
|
||||
? `${field.value} 이상`
|
||||
: ""
|
||||
}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
<div className={sonClass}>
|
||||
{
|
||||
//TODO : 확인필요
|
||||
}
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.smll`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.smll-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="냄새">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
field.onChange(String(e.target.value));
|
||||
}}
|
||||
value={field.value ?? ""}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
<div className={sonClass}>
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.crmty`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.crmty-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="색도(도)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
const inputValue = e.target.value.replace(/[^0-9.]/g, ""); // 숫자만 저장
|
||||
field.onChange(inputValue);
|
||||
}}
|
||||
value={
|
||||
field.value !== undefined && field.value !== ""
|
||||
? `${field.value} 이하`
|
||||
: ""
|
||||
}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
<div className={sonClass}>
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.tn`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.tn-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="총질소(T-N)(mg/L)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
const inputValue = e.target.value.replace(/[^0-9.]/g, ""); // 숫자만 저장
|
||||
field.onChange(inputValue);
|
||||
}}
|
||||
value={
|
||||
field.value !== undefined && field.value !== ""
|
||||
? `${field.value} 이하`
|
||||
: ""
|
||||
}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className={sonClass}>
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.tph`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.tph-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="총인(T-P)(mg/L)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
const inputValue = e.target.value.replace(/[^0-9.]/g, ""); // 숫자만 저장
|
||||
field.onChange(inputValue);
|
||||
}}
|
||||
value={
|
||||
field.value !== undefined && field.value !== ""
|
||||
? `${field.value} 이하`
|
||||
: ""
|
||||
}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
<div className={sonClass}>
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.cdtnv`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.cdtnv-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="전기전도도(μs/cm)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
const inputValue = e.target.value.replace(/[^0-9.]/g, ""); // 숫자만 저장
|
||||
field.onChange(inputValue);
|
||||
}}
|
||||
value={
|
||||
field.value !== undefined && field.value !== ""
|
||||
? `${field.value} 이하`
|
||||
: ""
|
||||
}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div className={sonClass}>
|
||||
<FormField
|
||||
control={form.control}
|
||||
name={`items.${indexMng}.fcBizs.${indexBiz}.clIonQnt`}
|
||||
key={`items.${indexMng}.fcBizs.${indexBiz}.clIonQnt-key`}
|
||||
render={({ field }) => (
|
||||
<FormUi label="염화물(mg/L)">
|
||||
<Input
|
||||
className="!text-2xl"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
const inputValue = e.target.value.replace(/[^0-9.]/g, ""); // 숫자만 저장
|
||||
field.onChange(inputValue);
|
||||
}}
|
||||
value={
|
||||
field.value !== undefined && field.value !== ""
|
||||
? `${field.value} 이하`
|
||||
: ""
|
||||
}
|
||||
readOnly={formType === "sttn" ? true : false}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</FormUi>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
<div className="col-span-8">
|
||||
<Label className="text-xl">수소이온농도(PH)</Label>
|
||||
<div className="flex flex-row items-center gap-2">
|
||||
<Input
|
||||
className="!text-2xl w-28"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) =>
|
||||
//setFrontPHdata(e.target.value)
|
||||
isSetFrontPh(e.target.value)
|
||||
}
|
||||
value={frontPHdata ?? ""}
|
||||
readOnly={formType === "sttn"}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
<span className="text-xl">~</span>
|
||||
<Input
|
||||
className="!text-2xl w-28"
|
||||
placeholder=""
|
||||
type="text"
|
||||
onChange={(e) => {
|
||||
isSetBackPh(e.target.value);
|
||||
}}
|
||||
value={backPHdata ?? ""}
|
||||
readOnly={formType === "sttn"}
|
||||
maxLength={txtSize}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user