fix[tagsView]: refresh bug (#1059)

#1051
This commit is contained in:
jiuwuxiaohun 2018-09-11 13:39:18 +08:00 committed by 花裤衩
parent 9c03dd3514
commit 0740bb36f7
2 changed files with 9 additions and 6 deletions

View File

@ -32,10 +32,12 @@ export default {
// In order to make the cached page re-rendered
this.$store.dispatch('delAllCachedViews', this.$route)
const { path } = this.$route
const { fullPath } = this.$route
this.$router.replace({
path: '/redirect' + path
this.$nextTick(() => {
this.$router.replace({
path: '/redirect' + fullPath
})
})
}
}

View File

@ -89,9 +89,10 @@ export default {
refreshSelectedTag(view) {
this.$store.dispatch('delCachedView', view).then(() => {
const { fullPath } = view
this.$router.replace({
path: '/redirect' + fullPath
this.$nextTick(() => {
this.$router.replace({
path: '/redirect' + fullPath
})
})
})
},