|
@@ -56,11 +56,13 @@ router.beforeEach((to, from, next) => {
|
|
|
|
|
|
if(to.path == '/') {
|
|
|
if(sessionstorage.getItem("isReload") === 'isReloadVlaue'){
|
|
|
- window.location.reload()
|
|
|
next()
|
|
|
+ window.location.reload()
|
|
|
+ console.log('有isReloadVlaue')
|
|
|
}else{
|
|
|
sessionStorage.setItem("isReload",'isReloadVlaue')
|
|
|
next()
|
|
|
+ console.log('无isReloadVlaue')
|
|
|
}
|
|
|
}else {
|
|
|
next()
|
|
@@ -70,9 +72,15 @@ router.beforeEach((to, from, next) => {
|
|
|
} else {
|
|
|
console.log('什么都有')
|
|
|
if(to.path == '/') {
|
|
|
- console.log('window.location.reload()')
|
|
|
- // window.location.reload()
|
|
|
- next()
|
|
|
+ if(sessionstorage.getItem("isReload") === 'isReloadVlaue'){
|
|
|
+ next()
|
|
|
+ window.location.reload()
|
|
|
+ console.log('有isReloadVlaue')
|
|
|
+ }else{
|
|
|
+ sessionStorage.setItem("isReload",'isReloadVlaue')
|
|
|
+ next()
|
|
|
+ console.log('无isReloadVlaue')
|
|
|
+ }
|
|
|
}else {
|
|
|
next()
|
|
|
}
|