Commit 092017ee by 温丽香

fixed

1 parent 4f17e150
Pipeline #4817 passed
in 2 minutes 13 seconds
Showing with 7 additions and 3 deletions
......@@ -227,7 +227,11 @@ export default {
}
const tableData = []
for (const value of this.baseData) {
tableData.push({ ...value, level: 0 })
if (value.type === 'object') {
tableData.push({ ...value, emit: true, level: 0 })
} else {
tableData.push({ ...value, level: 0 })
}
}
for (const value of this.currentData) {
tableData.push({ ...value, emit: true, level: 1 })
......@@ -254,7 +258,7 @@ export default {
},
handleDelete(index, row) {
if (!row.emit) {
this.tableData[index] = { ...row, type: 'null', value: null, emit: true, restore: true }
this.tableData[index] = { ...row, type: 'object', value: null, emit: true, restore: true }
} else {
this.tableData.splice(index, 1)
}
......@@ -270,7 +274,7 @@ export default {
tableData.push(tableDataTemp[i])
}
}
const scalarsArr = tableData.filter(item => item.type === 'string' || item.type === 'number' || item.type === 'null')
const scalarsArr = tableData.filter(item => item.type === 'string' || item.type === 'number' || item.type === 'object')
const binaryArr = tableData.filter(item => item.type === 'blob')
const tableArr = tableData.filter(item => item.type === 'table')
const scalarsObj = {}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!