perf: 优化OIDC用户未激活时,会循环跳转登录页面

This commit is contained in:
jiangweidong
2023-10-09 17:55:44 +08:00
committed by Bryan
parent 3d27986c96
commit 3ac35eec68
5 changed files with 110 additions and 98 deletions

View File

@@ -92,7 +92,7 @@ class ThirdPartyLoginMiddleware(mixins.AuthMixin):
'title': _('Authentication failed'),
'message': _('Authentication failed (before login check failed): {}').format(e),
'interval': 10,
'redirect_url': reverse('authentication:login'),
'redirect_url': reverse('authentication:login') + '?admin=0',
'auto_redirect': True,
}
response = render(request, 'authentication/auth_fail_flash_message_standalone.html', context)