diff --git a/src/layout/components/Navbar.vue b/src/layout/components/Navbar.vue index 250961a..d34212c 100644 --- a/src/layout/components/Navbar.vue +++ b/src/layout/components/Navbar.vue @@ -120,7 +120,7 @@ type: 'warning' }).then(() => { this.$store.dispatch('LogOut').then(() => { - location.href = '/index'; + location.href = '/ldlz/index'; }) }).catch(() => {}); }, diff --git a/src/router/index.js b/src/router/index.js index 488dc61..f198674 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -219,6 +219,7 @@ Router.prototype.replace = function push(location) { } export default new Router({ + base:'ldlz', mode: 'history', // 去掉url中的# scrollBehavior: () => ({ y: 0 }), routes: constantRoutes