From 3266039aafdb45d3af55682aa840d8b1811416cf Mon Sep 17 00:00:00 2001 From: "meilin.huang" <954537473@qq.com> Date: Tue, 4 Jul 2023 15:07:03 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=8F=8C=E5=87=BB=E4=BF=AE=E6=94=B9?= =?UTF-8?q?=E8=A1=A8sql=E9=97=AE=E9=A2=98=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mayfly_go_web/src/views/ops/db/component/DbTable.vue | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mayfly_go_web/src/views/ops/db/component/DbTable.vue b/mayfly_go_web/src/views/ops/db/component/DbTable.vue index bd91b6cb..6bcf27c6 100644 --- a/mayfly_go_web/src/views/ops/db/component/DbTable.vue +++ b/mayfly_go_web/src/views/ops/db/component/DbTable.vue @@ -172,7 +172,7 @@ const cellClick = (row: any, column: any, cell: any) => { const updateColumn = await dbInst.loadTableColumn(state.db, state.table, property); const newField = { div, row, - fieldName: column.rawColumnKey, + fieldName: property, fieldType: updateColumn.columnType, oldValue: text, newValue: input.value @@ -203,10 +203,10 @@ const cellClick = (row: any, column: any, cell: any) => { let fields = primaryKeyFields[0].fields const fieldsParam = fields.filter((a) => { - if (a.fieldName === column.rawColumnKey) { + if (a.fieldName === column.property) { a.newValue = input.value } - return a.fieldName === column.rawColumnKey + return a.fieldName === column.property }) const field = fieldsParam.length > 0 && fieldsParam[0] || {} as FieldsMeta @@ -216,7 +216,7 @@ const cellClick = (row: any, column: any, cell: any) => { let delIndex: number[] = []; currentUpdatedFields.forEach((a, i) => { if (a.primaryKey === primaryKeyValue) { - a.fields = a.fields && a.fields.length > 0 ? a.fields.filter(f => f.fieldName !== column.rawColumnKey) : []; + a.fields = a.fields && a.fields.length > 0 ? a.fields.filter(f => f.fieldName !== column.property) : []; a.fields.length <= 0 && delIndex.push(i) } });