테이블 추가기능 수정사항

This commit is contained in:
kjs
2025-09-23 10:40:21 +09:00
parent 474cc33aee
commit e653effac0
19 changed files with 1931 additions and 201 deletions

View File

@@ -38,7 +38,7 @@ export function CreateTableModal({ isOpen, onClose, onSuccess }: CreateTableModa
{
name: "",
label: "",
webType: "text",
inputType: "text",
nullable: true,
order: 1,
},
@@ -58,7 +58,7 @@ export function CreateTableModal({ isOpen, onClose, onSuccess }: CreateTableModa
{
name: "",
label: "",
webType: "text",
inputType: "text",
nullable: true,
order: 1,
},
@@ -134,7 +134,7 @@ export function CreateTableModal({ isOpen, onClose, onSuccess }: CreateTableModa
{
name: "",
label: "",
webType: "text",
inputType: "text",
nullable: true,
order: columns.length + 1,
},
@@ -150,7 +150,7 @@ export function CreateTableModal({ isOpen, onClose, onSuccess }: CreateTableModa
return;
}
const validColumns = columns.filter((col) => col.name && col.webType);
const validColumns = columns.filter((col) => col.name && col.inputType);
if (validColumns.length === 0) {
toast.error("최소 1개의 유효한 컬럼이 필요합니다.");
return;
@@ -188,7 +188,7 @@ export function CreateTableModal({ isOpen, onClose, onSuccess }: CreateTableModa
return;
}
const validColumns = columns.filter((col) => col.name && col.webType);
const validColumns = columns.filter((col) => col.name && col.inputType);
if (validColumns.length === 0) {
toast.error("최소 1개의 유효한 컬럼이 필요합니다.");
return;
@@ -220,7 +220,7 @@ export function CreateTableModal({ isOpen, onClose, onSuccess }: CreateTableModa
/**
* 폼 유효성 확인
*/
const isFormValid = !tableNameError && tableName && columns.some((col) => col.name && col.webType);
const isFormValid = !tableNameError && tableName && columns.some((col) => col.name && col.inputType);
return (
<Dialog open={isOpen} onOpenChange={onClose}>