From 551d871b0221a9c8a7adfd3263149844d6344f45 Mon Sep 17 00:00:00 2001 From: xuechunyuan <17853500702@163.com> Date: Tue, 23 May 2023 16:01:44 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=8C=E6=AC=A1=E7=A1=AE=E8=AE=A4=E5=BC=B9?= =?UTF-8?q?=E6=A1=86=E9=81=AE=E7=BD=A9=E5=B1=82=E7=82=B9=E5=87=BB=E4=BA=8B?= =?UTF-8?q?=E4=BB=B6=E5=8F=96=E6=B6=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/page/login/index.vue | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/page/login/index.vue b/src/page/login/index.vue index 7af36c2..1081264 100644 --- a/src/page/login/index.vue +++ b/src/page/login/index.vue @@ -47,22 +47,26 @@ export default { this.loading = false; console.log('err=======res',err) if(err.error == 'invalid_request') { - window.location.href = err.error_description+'?strToken=' + encodeURI(window.location);//重定向 + let url = err.error_description+'?retUrl=' + encodeURIComponent(window.location); + alert('重定向='+url) + window.location.href = url;//重定向 }else if(err.error == 'invalid_grant') { this.$confirm(err.error_description, '提示', { confirmButtonText: '确定', showClose: false, showCancelButton: false, - type: 'warning' + type: 'warning', + closeOnClickModal: false }).then(() => { this.$router.replace({ path: '/newlogin' }); }) }else { - this.$confirm(err.error_description, '提示', { + this.$confirm(err.error_description || '登录失败', '提示', { confirmButtonText: '确定', showClose: false, showCancelButton: false, - type: 'warning' + type: 'warning', + closeOnClickModal: false }).then(() => { this.$router.replace({ path: '/newlogin' }); })