fix: 解决前进撤回中锁定/隐藏无法正常实现的问题

This commit is contained in:
奔跑的面条
2022-10-01 19:59:57 +08:00
parent 4d9330983a
commit f470817c01
2 changed files with 53 additions and 43 deletions
@@ -169,18 +169,20 @@ export const useChartHistoryStore = defineStore({
this.createStackItem(item, HistoryActionTypeEnum.UN_GROUP, HistoryTargetTypeEnum.CHART)
},
// * 锁定记录
createLockHistory(
item: Array<CreateComponentType | CreateComponentGroupType>,
type: HistoryActionTypeEnum.LOCK | HistoryActionTypeEnum.UNLOCK
) {
this.createStackItem(item, type, HistoryTargetTypeEnum.CHART)
createLockHistory(item: Array<CreateComponentType | CreateComponentGroupType>) {
this.createStackItem(item, HistoryActionTypeEnum.LOCK, HistoryTargetTypeEnum.CHART)
},
// * 解锁记录
createUnLockHistory(item: Array<CreateComponentType | CreateComponentGroupType>) {
this.createStackItem(item, HistoryActionTypeEnum.UNLOCK, HistoryTargetTypeEnum.CHART)
},
// * 隐藏记录
createHideHistory(
item: Array<CreateComponentType | CreateComponentGroupType>,
type: HistoryActionTypeEnum.HIDE | HistoryActionTypeEnum.SHOW
) {
this.createStackItem(item, type, HistoryTargetTypeEnum.CHART)
createHideHistory(item: Array<CreateComponentType | CreateComponentGroupType>) {
this.createStackItem(item, HistoryActionTypeEnum.HIDE, HistoryTargetTypeEnum.CHART)
},
// * 展示记录
createShowHistory(item: Array<CreateComponentType | CreateComponentGroupType>) {
this.createStackItem(item, HistoryActionTypeEnum.SHOW, HistoryTargetTypeEnum.CHART)
}
}
})