mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-05-04 21:19:27 +08:00
fix: code review
This commit is contained in:
parent
302b159010
commit
e7de0607ce
@ -949,6 +949,9 @@ export const Table: any = withDynamicSchemaProps(
|
||||
const getRowKey = useCallback(
|
||||
(record: any, index) => {
|
||||
if (Array.isArray(rowKey)) {
|
||||
if (rowKey.length === 1) {
|
||||
return record[rowKey[0]];
|
||||
}
|
||||
return index;
|
||||
} else if (typeof rowKey === 'string') {
|
||||
return record[rowKey];
|
||||
|
Loading…
x
Reference in New Issue
Block a user