Revert "fix: table 添加 toggled: false 的列不参与持久化存储 (#5236)" (#8156)

This reverts commit e7c909b277.
This commit is contained in:
liaoxuezhi 2023-09-19 11:17:44 +08:00 committed by GitHub
parent 91f566f057
commit 665756e850
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1680,10 +1680,8 @@ export const TableStore = iRendererStore
localStorage.setItem(
key,
JSON.stringify({
// 可显示列index, 原始配置中存在 toggled: false 的列不持久化
toggledColumnIndex: self.activeToggaleColumns
.filter(item => !(item.pristine?.toggled === false))
.map(item => item.index),
// 可显示列index
toggledColumnIndex: self.activeToggaleColumns.map(item => item.index),
// 列排序namelabel可能不存在
columnOrder: self.columnsData.map(
item => item.name || item.label || item.rawIndex