mirror of
https://gitee.com/hhyykk/ipms-sjy.git
synced 2025-07-31 11:24:07 +08:00
fix: dict map
This commit is contained in:
@@ -66,6 +66,12 @@ export const useDictStore = defineStore('dict', {
|
||||
wsCache.set(CACHE_KEY.DICT_CACHE, dictDataMap, { exp: 60 }) // 60 秒 过期
|
||||
}
|
||||
},
|
||||
getDictByType(type: string) {
|
||||
if (!this.isSetDict) {
|
||||
this.setDictMap()
|
||||
}
|
||||
return this.dictMap[type]
|
||||
},
|
||||
async resetDict() {
|
||||
wsCache.delete(CACHE_KEY.DICT_CACHE)
|
||||
const res = await listSimpleDictDataApi()
|
||||
|
Reference in New Issue
Block a user