Commit e82bafa43ea98f538004830b86f0eb9a8624330b
Committed by
GitHub
1 parent
5fc28f92
fix: 修复EditCellTable 可编辑单元格当columns.ellipsis=true时,回调中取不到key的值。 (#1598)
Showing
1 changed file
with
2 additions
and
2 deletions
src/components/Table/src/components/editable/EditableCell.vue
... | ... | @@ -265,7 +265,7 @@ |
265 | 265 | result = await beforeEditSubmit({ |
266 | 266 | record: pick(record, keys), |
267 | 267 | index, |
268 | - key: key as string, | |
268 | + key: dataKey as string, | |
269 | 269 | value, |
270 | 270 | }); |
271 | 271 | } catch (e) { |
... | ... | @@ -281,7 +281,7 @@ |
281 | 281 | |
282 | 282 | set(record, dataKey, value); |
283 | 283 | //const record = await table.updateTableData(index, dataKey, value); |
284 | - needEmit && table.emit?.('edit-end', { record, index, key, value }); | |
284 | + needEmit && table.emit?.('edit-end', { record, index, key: dataKey, value }); | |
285 | 285 | isEdit.value = false; |
286 | 286 | } |
287 | 287 | ... | ... |