perf: mfa interface optimization, mobile phone number can be empty

This commit is contained in:
feng
2024-05-28 16:09:22 +08:00
committed by Bryan
parent f95cbd6977
commit 91a1da57e9
9 changed files with 215 additions and 104 deletions

View File

@@ -44,13 +44,13 @@ class MFASms(BaseMFA):
return settings.SMS_ENABLED
def get_enable_url(self) -> str:
return '/ui/#/profile/setting?activeTab=ProfileUpdate'
return '/ui/#/profile/index'
def can_disable(self) -> bool:
return True
def disable(self):
return '/ui/#/profile/setting?activeTab=ProfileUpdate'
return '/ui/#/profile/index'
@staticmethod
def help_text_of_enable():
@@ -61,4 +61,4 @@ class MFASms(BaseMFA):
return _("Clear phone number to disable")
def get_disable_url(self) -> str:
return '/ui/#/profile/setting?activeTab=ProfileUpdate'
return '/ui/#/profile/index'