fix
This commit is contained in:
@@ -17,8 +17,6 @@ import { Https } from "@/tool/https";
|
||||
|
||||
flexible()
|
||||
import { getCookie, setCookie } from "@/tool/cookie";
|
||||
|
||||
import { useI18n } from 'vue-i18n';
|
||||
// console.log(process.env)
|
||||
let token = getCookie("token");
|
||||
let routerName:any = router.currentRoute
|
||||
@@ -58,6 +56,7 @@ async function isMurmur() {
|
||||
let randomNum: any = Math.floor(Math.random() * 9000000000000000) + 1000000000000000;
|
||||
sessionStorage.setItem('sessionId', randomNum);
|
||||
router.push("/home");
|
||||
localStorage.setItem('murmurStr',murmurStr)
|
||||
})
|
||||
.catch((res) => {
|
||||
});
|
||||
|
||||
@@ -97,6 +97,8 @@ router.beforeEach((to, from, next) => {
|
||||
let isMurmur = JSON.parse(getIsMurmur)
|
||||
if(isMurmur&& murmurStr){
|
||||
const toName = to.name === 'login';
|
||||
console.log(to);
|
||||
|
||||
if (toName) {
|
||||
next({ name: 'home' });
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user