fix: 完善单测demo(indexedDB相关)

This commit is contained in:
chenjinsong
2023-01-17 17:56:44 +08:00
parent 38006bd964
commit 04e186e7d8
9 changed files with 88 additions and 36 deletions

View File

@@ -215,8 +215,8 @@ import unitConvert from '@/utils/unit-convert'
import { getChainRatio, computeScore, urlParamsHandler, overwriteUrl, readDrilldownTableConfigByUser, combineDrilldownTableWithUserConfig, getDnsMapData, handleSpecialValue, getConfigVersion } from '@/utils/tools'
import { getSecond } from '@/utils/date-util'
import chartMixin from '@/views/charts2/chart-mixin'
import { db } from '@/indexedDB'
import _ from 'lodash'
import indexedDBUtils from '@/indexedDB'
export default {
name: 'NetworkOverviewTabs',
@@ -1729,7 +1729,7 @@ export default {
version = await getConfigVersion('default')
}
// 更新缓存中的配置
await db[dbDrilldownTableConfig].put({
await indexedDBUtils.selectTable(dbDrilldownTableConfig).put({
id: this.userId,
version: version,
config: this.$_.cloneDeep(curUserConfigGroup)