fix: 重置密钥到auth中

pull/4070/head
ibuler 2020-06-03 12:44:45 +08:00
parent 999286a089
commit 5bacab7475
2 changed files with 3 additions and 2 deletions

View File

@ -25,6 +25,7 @@ urlpatterns = [
path('password/verify/', users_view.UserVerifyPasswordView.as_view(), name='user-verify-password'),
# Profile
path('profile/pubkey/generate/', users_view.UserPublicKeyGenerateView.as_view(), name='user-pubkey-generate'),
path('profile/otp/enable/start/', users_view.UserOtpEnableStartView.as_view(), name='user-otp-enable-start'),
path('profile/otp/enable/install-app/', users_view.UserOtpEnableInstallAppView.as_view(),
name='user-otp-enable-install-app'),

View File

@ -205,8 +205,8 @@ def get_user_or_pre_auth_user(request):
def redirect_user_first_login_or_index(request, redirect_field_name):
if request.user.is_first_login:
return reverse('authentication:user-first-login')
# if request.user.is_first_login:
# return reverse('authentication:user-first-login')
url_in_post = request.POST.get(redirect_field_name)
if url_in_post:
return url_in_post