登录页oss配置请求问题
continuous-integration/drone/push Build is passing Details

main
wangxiaoshuang 2024-11-27 10:50:53 +08:00
parent b8279e1f4c
commit 8a55cfcad7
1 changed files with 5 additions and 1 deletions

View File

@ -23,6 +23,7 @@ Vue.prototype.$setOpenWindow = (openWindow) => {
// 时间格式化
Vue.prototype.$moment = moment;
router.beforeEach(async (to, from, next) => {
console.log(to, 'to')
NProgress.start()
Vue.prototype.$setOpenWindow();
// 设置页面标题
@ -35,12 +36,15 @@ router.beforeEach(async (to, from, next) => {
if (hasToken) {
if (to.path === '/login' || to.path === '/recompose' || to.path === '/email-recompose' || to.path === '/error' || to.path === '/ReviewersResearchForm' || to.path === '/ReviewersResearch') {
if (to.path === '/ReviewersResearch') {
await this.$store.dispatch('user/logout')
OSSclient()
await this.$store.dispatch('user/logout')
}
if (to.path === '/ReviewersResearchForm') {
OSSclient()
}
if (to.path === '/login') {
OSSclient()
}
next()
NProgress.done()
} else {