fix(테이블타입): IDX/label API payload key snake_case 로 통일
테이블 타입 관리 페이지에서 IDX 토글 / 테이블 라벨 저장이 400 에러로
조용히 실패하던 버그. 백엔드는 body.get("column_name") / get("index_type")
/ get("display_name") 등 snake_case 로 읽는데 프론트가 camelCase 로 보내고
있었음 (CLAUDE.md Map key snake_case 컨벤션 위반).
- POST /table-management/tables/:t/indexes
{ columnName, indexType, action } → { column_name, index_type, action }
- PUT /table-management/tables/:t/label
{ displayName } → { display_name }
PK 는 다이얼로그 확인 흐름, NN/UQ 는 key 가 맞아 영향 없음.
SUPER_ADMIN 으로 테스트 시 IDX 만 안 되던 증상 일치.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -756,7 +756,7 @@ export default function TableManagementPage() {
|
|||||||
if (tableLabel !== selectedTable || tableDescription) {
|
if (tableLabel !== selectedTable || tableDescription) {
|
||||||
try {
|
try {
|
||||||
await apiClient.put(`/table-management/tables/${selectedTable}/label`, {
|
await apiClient.put(`/table-management/tables/${selectedTable}/label`, {
|
||||||
displayName: tableLabel,
|
display_name: tableLabel,
|
||||||
description: tableDescription,
|
description: tableDescription,
|
||||||
});
|
});
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
@@ -1055,8 +1055,8 @@ export default function TableManagementPage() {
|
|||||||
const action = checked ? "create" : "drop";
|
const action = checked ? "create" : "drop";
|
||||||
try {
|
try {
|
||||||
const response = await apiClient.post(`/table-management/tables/${selectedTable}/indexes`, {
|
const response = await apiClient.post(`/table-management/tables/${selectedTable}/indexes`, {
|
||||||
columnName,
|
column_name: columnName,
|
||||||
indexType,
|
index_type: indexType,
|
||||||
action,
|
action,
|
||||||
});
|
});
|
||||||
if (response.data.success) {
|
if (response.data.success) {
|
||||||
|
|||||||
Reference in New Issue
Block a user