Skip to content

Commit

Permalink
Merge pull request #3167 from VisActor/fix/fs-bs
Browse files Browse the repository at this point in the history
fix: fix no records in initRecordCheckState()
  • Loading branch information
Rui-Sun authored Dec 20, 2024
2 parents b656026 + ea50d63 commit f92ec58
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/vtable/src/state/checkbox/checkbox.ts
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,13 @@ function initRecordCheckState(records: any[], state: StateManager) {
: table.internalProps.transpose
? table.rowHeaderLevelCount
: table.columnHeaderLevelCount;
const end = table.isPivotTable() ? records.length : table.internalProps.transpose ? table.colCount : table.rowCount;
const end = table.isPivotTable()
? isArray(records)
? records.length
: 0
: table.internalProps.transpose
? table.colCount
: table.rowCount;
for (let index = 0; index + start < end; index++) {
const record = table.isPivotTable() ? records[index] : table.dataSource.get(index);
// eslint-disable-next-line no-loop-func
Expand Down

0 comments on commit f92ec58

Please sign in to comment.