This commit is contained in:
X1627315083
2024-01-15 17:36:24 +08:00
parent 214457a2f6
commit af500def80
2 changed files with 3 additions and 2 deletions

View File

@@ -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) => {
});

View File

@@ -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 {