mirror of
https://github.com/vbenjs/gf-vben-admin.git
synced 2025-02-03 03:32:59 +08:00
Fix the return value when editing the cell(#219)
修正单元格编辑提交时的返回值 .这个地方应该返回真实值,而不是editValueMap处理后的值或Select插槽的option.label。
This commit is contained in:
parent
61cf0f791e
commit
1a85dff57d
@ -227,12 +227,12 @@
|
|||||||
if (!isPass) return false;
|
if (!isPass) return false;
|
||||||
const { column, index } = props;
|
const { column, index } = props;
|
||||||
const { key, dataIndex } = column;
|
const { key, dataIndex } = column;
|
||||||
// const value = unref(currentValueRef);
|
const value = unref(currentValueRef);
|
||||||
if (!key || !dataIndex) return;
|
if (!key || !dataIndex) return;
|
||||||
const dataKey = (dataIndex || key) as string;
|
const dataKey = (dataIndex || key) as string;
|
||||||
|
|
||||||
const record = await table.updateTableData(index, dataKey, unref(getValues));
|
const record = await table.updateTableData(index, dataKey, value);
|
||||||
needEmit && table.emit?.('edit-end', { record, index, key, value: unref(currentValueRef) });
|
needEmit && table.emit?.('edit-end', { record, index, key, value});
|
||||||
isEdit.value = false;
|
isEdit.value = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user