Skip to content

Commit

Permalink
Merge pull request #1106 from longguikeji/v2.5-dev
Browse files Browse the repository at this point in the history
V2.5 dev
  • Loading branch information
welylongguikeji committed Aug 1, 2022
2 parents 9871e61 + 4c655ae commit 8d5e054
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion arkid/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@
# arkid_saas
IS_CENTRAL_ARKID = False # 是否为中心ARKID
ARKID_SAAS_URL = 'https://central.arkid.cc' # 中心ARKID链接
ARKSTOER_URL = 'https://arkstore.longuikeji.com' # 插件商店链接
ARKSTOER_URL = 'https://arkstore.longguikeji.com' # 插件商店链接

# 引入settings_local.py 本地配置文件
if os.path.exists(os.path.join(BASE_DIR, 'settings_local.py')):
Expand Down
8 changes: 4 additions & 4 deletions extension_root/com_longgui_auth_factor_password/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ def authenticate(self, event, **kwargs):


config = TenantExtensionConfig.active_objects.get(id=config_id).config
login_enabled_field_names = [item["key"] for item in config.get('login_enabled_field_names')]
login_enabled_field_names = [item["key"] if isinstance(item,dict) else item for item in config.get('login_enabled_field_names')]
filter_params = None
for lefn in login_enabled_field_names:
temp = {lefn:username}
Expand Down Expand Up @@ -218,7 +218,7 @@ def register(self, event, **kwargs):
if not ret:
return self.error(ErrorCode.PASSWORD_STRENGTH_LACK)

register_fields = [item["key"] for item in config.config.get('register_enabled_field_names')]
register_fields = [item["key"] if isinstance(item,dict) else item for item in config.config.get('register_enabled_field_names')]
if not register_fields:
fields = ['username']
if username is None:
Expand Down Expand Up @@ -250,7 +250,7 @@ def reset_password(self, event, **kwargs):

def create_login_page(self, event, config, config_data):
username_placeholder = ""
for lefn in [item["key"] for item in config.config.get('login_enabled_field_names',[])]:
for lefn in [item["key"] if isinstance(item,dict) else item for item in config.config.get('login_enabled_field_names',[])]:
if username_placeholder:
username_placeholder = ',' + User.key_fields[lefn]
else:
Expand All @@ -271,7 +271,7 @@ def create_login_page(self, event, config, config_data):

def create_register_page(self, event, config, config_data):
items = []
register_fields = [item["key"] for item in config.config.get('register_enabled_field_names')]
register_fields = [item["key"] if isinstance(item,dict) else item for item in config.config.get('register_enabled_field_names')]
for rf in register_fields:
items.append({
"type": "text",
Expand Down

0 comments on commit 8d5e054

Please sign in to comment.