From 7d95ddf6a521f108b3b49d71760ba6e92a56d2dc Mon Sep 17 00:00:00 2001 From: truthwing Date: Tue, 22 Jul 2025 13:55:31 +0900 Subject: [PATCH] =?UTF-8?q?ChkClass=20=ED=83=80=EC=9E=85=EC=9D=98=20?= =?UTF-8?q?=EC=A0=95=EB=B3=B4=EB=A1=9C=20=EB=8F=99=EC=9E=91=EB=90=98?= =?UTF-8?q?=EB=8A=94=20=EC=B2=B4=ED=81=AC=EB=B0=95=EC=8A=A4=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../business_components/src/ui/table/index.tsx | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/packages/common/business_components/src/ui/table/index.tsx b/packages/common/business_components/src/ui/table/index.tsx index 85ffb85ea..b4a66d839 100644 --- a/packages/common/business_components/src/ui/table/index.tsx +++ b/packages/common/business_components/src/ui/table/index.tsx @@ -5,7 +5,10 @@ import { useEffect, useState, useRef } from "react"; import { HeadMakeColSpan } from "./HeadMakeColSpan"; import UiPageNations from "./uiPageNations"; import { Check } from "lucide-react"; - +export type ChkClass={ + chk:boolean + readonly:boolean +} type UiTableProps = { headName: React.ReactNode | undefined; tableData: { [key: string]: any }[]; @@ -109,7 +112,17 @@ export function UiTable({ tableData, headlist, pageSize, total, headName, childr onClick={() => handleCellClick(index, head.id)} key={`cell-${head.id}-${index}`} > - {typeof el[head.id] === 'boolean' + {typeof el[head.id] === 'object' + ? { + if((el[head.id] as ChkClass).readonly == true) return + (el[head.id] as ChkClass).chk = Boolean(checked); + }} + > + + : + typeof el[head.id] === 'boolean' ? {