From 94d56d71be6d7d285a7018375e647cf2c4343e98 Mon Sep 17 00:00:00 2001 From: LokerL Date: Sun, 24 Nov 2024 18:21:49 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20feat:=20=E6=B7=BB=E5=8A=A0sso=20red?= =?UTF-8?q?irect=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-ui/src/permission.js | 2 +- ruoyi-ui/src/router/index.js | 5 +++++ ruoyi-ui/src/views/login-redirect.vue | 24 ++++++++++++++++++++++++ ruoyi-ui/src/views/login-sso.vue | 6 ------ 4 files changed, 30 insertions(+), 7 deletions(-) create mode 100644 ruoyi-ui/src/views/login-redirect.vue diff --git a/ruoyi-ui/src/permission.js b/ruoyi-ui/src/permission.js index 5abf76a..228d79d 100644 --- a/ruoyi-ui/src/permission.js +++ b/ruoyi-ui/src/permission.js @@ -8,7 +8,7 @@ import { isRelogin } from '@/utils/request' NProgress.configure({ showSpinner: false }) -const whiteList = ['/login', '/register', '/LoginSso'] +const whiteList = ['/login', '/register', '/LoginSso', '/LoginRedirect'] router.beforeEach((to, from, next) => { NProgress.start() diff --git a/ruoyi-ui/src/router/index.js b/ruoyi-ui/src/router/index.js index 6219c15..0e16abd 100644 --- a/ruoyi-ui/src/router/index.js +++ b/ruoyi-ui/src/router/index.js @@ -51,6 +51,11 @@ export const constantRoutes = [ component: () => import('@/views/login-sso'), hidden: true }, + { + path: '/LoginRedirect', + component: () => import('@/views/login-redirect'), + hidden: true + }, { path: '/register', component: () => import('@/views/register'), diff --git a/ruoyi-ui/src/views/login-redirect.vue b/ruoyi-ui/src/views/login-redirect.vue new file mode 100644 index 0000000..efd50e4 --- /dev/null +++ b/ruoyi-ui/src/views/login-redirect.vue @@ -0,0 +1,24 @@ + +​ + diff --git a/ruoyi-ui/src/views/login-sso.vue b/ruoyi-ui/src/views/login-sso.vue index 4221c3f..2844dfc 100644 --- a/ruoyi-ui/src/views/login-sso.vue +++ b/ruoyi-ui/src/views/login-sso.vue @@ -7,11 +7,6 @@ export default { name: "LoginSso", data() { return { - loginRules: {}, - //验证码开关 - captchaOnOff: true, - //注册开关 - register: false, //重定向 redirect: undefined }; @@ -24,7 +19,6 @@ export default { loginSso() { //获取地址栏中的code const code = this.$route.query.code; - console.log("code="+code) //调用登录的接口 if(code==''||code==undefined||code==null){ //请求中不带code,拦截为正常登录