diff --git a/src/App.vue b/src/App.vue index 5254b68..a285f4a 100644 --- a/src/App.vue +++ b/src/App.vue @@ -25,7 +25,7 @@ import { useStore } from "vuex"; import { boeRequest } from "@/api/request"; import { GET_USER_INFO } from "@/api/ThirdApi"; import { getCookie } from "@/api/utils"; - +console.log("版本1.2.0------------"); const store = useStore(); const router = useRouter(); diff --git a/src/router/index.js b/src/router/index.js index 2728bca..7884067 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -1,6 +1,6 @@ -import {createRouter, createWebHashHistory, createWebHistory} from 'vue-router'; +import { createRouter, createWebHashHistory, createWebHistory } from 'vue-router'; import routesConfig from './config'; -import {getCookie} from "@/api/utils"; +import { getCookie } from "@/api/utils"; // console.log('routesConfig', routesConfig) const routes = [ @@ -19,9 +19,9 @@ const router = createRouter({ router.beforeEach((to, from, next) => { if (!getCookie('token')) { if (import.meta.env.MODE === "development" || import.meta.env.MODE === "test") { - to.path.includes('/login') ? next() : next({path: '/login', query: {returnUrl: to.fullPath}}) - }else { - window.location.href = import.meta.env.VITE_BASE_LOGIN_URL + import.meta.env.VITE_BASE+to.fullPath + to.path.includes('/login') ? next() : next({ path: '/login', query: { returnUrl: to.fullPath } }) + } else { + window.location.href = import.meta.env.VITE_BASE_LOGIN_URL + import.meta.env.VITE_BASE + to.fullPath } } next() diff --git a/src/views/faceteach/FaceTeach.vue b/src/views/faceteach/FaceTeach.vue index bb0ee61..667b12b 100644 --- a/src/views/faceteach/FaceTeach.vue +++ b/src/views/faceteach/FaceTeach.vue @@ -218,12 +218,7 @@ -
-
-
-
-
+
+