From dfdcdcb3dbd0b711bc0b77bb00fd1d39af91bd0b Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期五, 10 一月 2025 17:43:34 +0800 Subject: [PATCH] 2025-01-10 --- src/api/cacheutils.js | 18 +++++------------- 1 files changed, 5 insertions(+), 13 deletions(-) diff --git a/src/api/cacheutils.js b/src/api/cacheutils.js index bd14fa5..b20d3f6 100644 --- a/src/api/cacheutils.js +++ b/src/api/cacheutils.js @@ -27,9 +27,9 @@ if (!window.GLOB.IndexDB.objectStoreNames.contains('caches')) { window.GLOB.IndexDB.createObjectStore('caches', { keyPath: 'menuid' }) } - if (!window.GLOB.IndexDB.objectStoreNames.contains('funcs')) { - window.GLOB.IndexDB.createObjectStore('funcs', { keyPath: 'id' }) - } + // if (!window.GLOB.IndexDB.objectStoreNames.contains('funcs')) { + // window.GLOB.IndexDB.createObjectStore('funcs', { keyPath: 'id' }) + // } } } catch (e) { console.warn('IndexedDB 鍒濆鍖栧け璐ワ紒') @@ -204,7 +204,7 @@ /** * @description 鑾峰彇IndexedDB涓殑閰嶇疆淇℃伅 */ - static getIndexDBCacheConfig (MenuID, limit) { + static getIndexDBCacheConfig (MenuID) { if (!window.GLOB.IndexDB) return Promise.resolve() return new Promise((resolve, reject) => { @@ -215,15 +215,7 @@ } request.onsuccess = () => { - if (limit && request.result) { - if (request.result.CreateDate > limit) { - resolve(request.result) - } else { - resolve() - } - } else { - resolve(request.result) - } + resolve(request.result) } }) } -- Gitblit v1.8.0