每日进入刷新缓存
This commit is contained in:
@@ -77,7 +77,7 @@
|
||||
<script src="${base!}/assets/platform/js/v.js?v=1.0.5"></script>
|
||||
<script src="${base!}/assets/platform/plugins/wangeditor/wangEditor.js"></script>
|
||||
<!-- <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/wangeditor@4.6.15/dist/wangEditor.min.js"></script>-->
|
||||
<!-- <script
|
||||
<!-- <script
|
||||
type="text/javascript"
|
||||
src="https://webapi.amap.com/maps?v=1.4.15&key=6ab3452804ba35050880b5e047436853&plugin=AMap.PolyEditor,AMap.PlaceSearch"
|
||||
></script>-->
|
||||
@@ -502,6 +502,16 @@
|
||||
|
||||
});
|
||||
},
|
||||
async flushCache(){
|
||||
const day = moment().format('YYYY-MM-DD')
|
||||
if (window.localStorage.getItem('flushCache') !== day) {
|
||||
const {code, msg} = await $.post('/platform/home/clearCache')
|
||||
if (code === 0) {
|
||||
location.reload()
|
||||
}
|
||||
window.localStorage.setItem('flushCache', day)
|
||||
}
|
||||
},
|
||||
findParentNodes(data, targetHref, parents = []) {
|
||||
for (const node of data) {
|
||||
if (node && node.href === targetHref) {
|
||||
@@ -540,6 +550,7 @@
|
||||
created() {
|
||||
this.matchMenu()
|
||||
this.getUnReadMsgNum()
|
||||
this.flushCache()
|
||||
}
|
||||
})
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user