perf: Modify i18n for settings module. (#12543)

Co-authored-by: Bai <baijiangjie@gmail.com>
pull/12555/head
fit2bot 2024-01-15 19:41:50 +08:00 committed by GitHub
parent fcb4c6a972
commit fdaec3c959
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 29 additions and 38 deletions

View File

@ -5019,7 +5019,7 @@ msgid "Passkey Auth"
msgstr "Passkey 認証" msgstr "Passkey 認証"
#: settings/serializers/auth/base.py:26 #: settings/serializers/auth/base.py:26
msgid "Forgot password url" msgid "Forgot Password URL"
msgstr "パスワードのURLを忘れた" msgstr "パスワードのURLを忘れた"
#: settings/serializers/auth/base.py:29 #: settings/serializers/auth/base.py:29
@ -5184,7 +5184,7 @@ msgid "OIDC"
msgstr "OIDC" msgstr "OIDC"
#: settings/serializers/auth/oidc.py:16 #: settings/serializers/auth/oidc.py:16
msgid "Base site url" msgid "Base site URL"
msgstr "ベースサイトのアドレス" msgstr "ベースサイトのアドレス"
#: settings/serializers/auth/oidc.py:32 #: settings/serializers/auth/oidc.py:32
@ -5430,7 +5430,7 @@ msgid "Enable WeCom Auth"
msgstr "企業微信認証の有効化" msgstr "企業微信認証の有効化"
#: settings/serializers/basic.py:11 #: settings/serializers/basic.py:11
msgid "Site url" msgid "Site URL"
msgstr "サイトURL" msgstr "サイトURL"
#: settings/serializers/basic.py:13 #: settings/serializers/basic.py:13
@ -5450,7 +5450,7 @@ msgid "User first login update profile done redirect to it"
msgstr "ユーザーの最初のログイン更新プロファイルがリダイレクトされました" msgstr "ユーザーの最初のログイン更新プロファイルがリダイレクトされました"
#: settings/serializers/basic.py:22 #: settings/serializers/basic.py:22
msgid "Global organization name" msgid "Global organization"
msgstr "グローバル組織名" msgstr "グローバル組織名"
#: settings/serializers/basic.py:23 #: settings/serializers/basic.py:23
@ -5526,7 +5526,7 @@ msgid "Subject"
msgstr "件名" msgstr "件名"
#: settings/serializers/feature.py:22 #: settings/serializers/feature.py:22
msgid "More url" msgid "More URL"
msgstr "もっとURL" msgstr "もっとURL"
#: settings/serializers/feature.py:36 settings/serializers/feature.py:39 #: settings/serializers/feature.py:36 settings/serializers/feature.py:39
@ -5569,7 +5569,7 @@ msgid "Enable Chat AI"
msgstr "チャットAIを起動する" msgstr "チャットAIを起動する"
#: settings/serializers/feature.py:78 #: settings/serializers/feature.py:78
msgid "Base Url" msgid "Base URL"
msgstr "基本的なUrl" msgstr "基本的なUrl"
#: settings/serializers/feature.py:81 templates/_header_bar.html:90 #: settings/serializers/feature.py:81 templates/_header_bar.html:90

View File

@ -4964,7 +4964,7 @@ msgid "Passkey Auth"
msgstr "Passkey 认证" msgstr "Passkey 认证"
#: settings/serializers/auth/base.py:26 #: settings/serializers/auth/base.py:26
msgid "Forgot password url" msgid "Forgot Password URL"
msgstr "忘记密码 URL" msgstr "忘记密码 URL"
#: settings/serializers/auth/base.py:29 #: settings/serializers/auth/base.py:29
@ -5129,7 +5129,7 @@ msgid "OIDC"
msgstr "OIDC" msgstr "OIDC"
#: settings/serializers/auth/oidc.py:16 #: settings/serializers/auth/oidc.py:16
msgid "Base site url" msgid "Base site URL"
msgstr "JumpServer 地址" msgstr "JumpServer 地址"
#: settings/serializers/auth/oidc.py:32 #: settings/serializers/auth/oidc.py:32
@ -5372,7 +5372,7 @@ msgid "Enable WeCom Auth"
msgstr "启用企业微信认证" msgstr "启用企业微信认证"
#: settings/serializers/basic.py:11 #: settings/serializers/basic.py:11
msgid "Site url" msgid "Site URL"
msgstr "当前站点 URL" msgstr "当前站点 URL"
#: settings/serializers/basic.py:13 #: settings/serializers/basic.py:13
@ -5392,7 +5392,7 @@ msgid "User first login update profile done redirect to it"
msgstr "用户第一次登录修改profile后重定向到地址, 可以是 wiki 或 其他说明文档" msgstr "用户第一次登录修改profile后重定向到地址, 可以是 wiki 或 其他说明文档"
#: settings/serializers/basic.py:22 #: settings/serializers/basic.py:22
msgid "Global organization name" msgid "Global organization"
msgstr "全局组织名" msgstr "全局组织名"
#: settings/serializers/basic.py:23 #: settings/serializers/basic.py:23
@ -5467,7 +5467,7 @@ msgid "Subject"
msgstr "主题" msgstr "主题"
#: settings/serializers/feature.py:22 #: settings/serializers/feature.py:22
msgid "More url" msgid "More URL"
msgstr "更多信息 URL" msgstr "更多信息 URL"
#: settings/serializers/feature.py:36 settings/serializers/feature.py:39 #: settings/serializers/feature.py:36 settings/serializers/feature.py:39
@ -5509,7 +5509,7 @@ msgid "Enable Chat AI"
msgstr "启动聊天 AI" msgstr "启动聊天 AI"
#: settings/serializers/feature.py:78 #: settings/serializers/feature.py:78
msgid "Base Url" msgid "Base URL"
msgstr "基本地址" msgstr "基本地址"
#: settings/serializers/feature.py:81 templates/_header_bar.html:90 #: settings/serializers/feature.py:81 templates/_header_bar.html:90

View File

@ -95,7 +95,6 @@
"AdminUserList": "Admin Users", "AdminUserList": "Admin Users",
"AdminUserListHelpMessage": "Admin users are asset (charged server) on the root, or have NOPASSWD: ALL sudo permissions users, JumpServer users of the system using the user to `push system user`, `get assets hardware information`, etc.\n", "AdminUserListHelpMessage": "Admin users are asset (charged server) on the root, or have NOPASSWD: ALL sudo permissions users, JumpServer users of the system using the user to `push system user`, `get assets hardware information`, etc.\n",
"AdminUserUpdate": "Admin user update", "AdminUserUpdate": "Admin user update",
"AdminUsersAmount": "Admin users amount",
"Advanced": "Advanced", "Advanced": "Advanced",
"AfterChange": "After the change", "AfterChange": "After the change",
"AjaxError404": "404 ajax error", "AjaxError404": "404 ajax error",
@ -116,7 +115,6 @@
"ApiKeyList": "The API key is used to sign the request header. The header of each request is different. Please refer to the usage documentation", "ApiKeyList": "The API key is used to sign the request header. The header of each request is different. Please refer to the usage documentation",
"ApiKeyWarning": "To reduce the risk of AccessKey exposure, Secret is provided only during creation and cannot be queried again later. Please keep it safe.", "ApiKeyWarning": "To reduce the risk of AccessKey exposure, Secret is provided only during creation and cannot be queried again later. Please keep it safe.",
"App": "Application", "App": "Application",
"AppAmount": "Application amount",
"AppAuth": "App auth", "AppAuth": "App auth",
"AppChangeAuthPlan": "App Change Auth Plan", "AppChangeAuthPlan": "App Change Auth Plan",
"AppChangeAuthPlanCreate": "Create App change auth plan", "AppChangeAuthPlanCreate": "Create App change auth plan",
@ -126,7 +124,6 @@
"AppName": "App name", "AppName": "App name",
"AppOps": "Task center", "AppOps": "Task center",
"AppPath": "App path", "AppPath": "App path",
"AppPermsAmount": "App perms amount",
"AppProvider": "App provider", "AppProvider": "App provider",
"AppProviderDetail": "Provider Detail", "AppProviderDetail": "Provider Detail",
"AppType": "App type", "AppType": "App type",
@ -150,7 +147,6 @@
"ApplicationPermissionRules": "Application permission rules", "ApplicationPermissionRules": "Application permission rules",
"ApplicationPermissionUpdate": "Application permission update", "ApplicationPermissionUpdate": "Application permission update",
"Applications": "Applications", "Applications": "Applications",
"ApplicationsAmount": "Applications amount",
"ApplyAsset": "Apply asset", "ApplyAsset": "Apply asset",
"ApplyFromCMDFilterRule": "Command filter rule", "ApplyFromCMDFilterRule": "Command filter rule",
"ApplyFromSession": "Session", "ApplyFromSession": "Session",
@ -182,7 +178,7 @@
"AssetAddress": "IP/Host", "AssetAddress": "IP/Host",
"AssetAmount": "Asset", "AssetAmount": "Asset",
"AssetAndNode": "Assets and node", "AssetAndNode": "Assets and node",
"AssetBulkUpdateTips": "device、cloud、webBatch update of domain is not supported", "AssetBulkUpdateTips": "device、cloud、web, Batch update of domain is not supported",
"AssetChangeAuthPlan": "Asset Change Auth Plan", "AssetChangeAuthPlan": "Asset Change Auth Plan",
"AssetChangeAuthPlanCreate": "Create Asset change auth plan", "AssetChangeAuthPlanCreate": "Create Asset change auth plan",
"AssetChangeAuthPlanUpdate": "Update Asset change auth plan", "AssetChangeAuthPlanUpdate": "Update Asset change auth plan",
@ -206,7 +202,7 @@
"AssetPermissionList": "Asset permission list", "AssetPermissionList": "Asset permission list",
"AssetPermissionRules": "Asset permission rules", "AssetPermissionRules": "Asset permission rules",
"AssetPermissionUpdate": "Asset permissions update", "AssetPermissionUpdate": "Asset permissions update",
"AssetPermsAmount": "Asset perms amount", "AssetPermsAmount": "Permissions",
"AssetProtocolHelpText": "Asset support protocol is limited by platform, click the Settings button to view the protocol settings. If you need to update, please update the platform", "AssetProtocolHelpText": "Asset support protocol is limited by platform, click the Settings button to view the protocol settings. If you need to update, please update the platform",
"AssetRatio": "Asset radio", "AssetRatio": "Asset radio",
"AssetResultDetail": "Asset result", "AssetResultDetail": "Asset result",
@ -214,7 +210,7 @@
"AssetUpdate": "Asset update", "AssetUpdate": "Asset update",
"AssetUserList": "Asset user", "AssetUserList": "Asset user",
"Assets": "Assets", "Assets": "Assets",
"AssetsAmount": "Assets amount", "AssetsAmount": "Assets",
"AssetsTotal": "Asset total", "AssetsTotal": "Asset total",
"AssignedInfo": "Assigned Info", "AssignedInfo": "Assigned Info",
"AssignedMe": "Assigned me", "AssignedMe": "Assigned me",
@ -229,7 +225,7 @@
"AttrValue": "Attribute Value", "AttrValue": "Attribute Value",
"Auditor": "Auditor", "Auditor": "Auditor",
"Audits": "Audit", "Audits": "Audit",
"Auth": "Auth", "Auth": "Authentications",
"AuthCASAttrMap": "User Attribute Mapping", "AuthCASAttrMap": "User Attribute Mapping",
"AuthLdap": "Enable LDAP auth", "AuthLdap": "Enable LDAP auth",
"AuthLdapBindDn": "Bind DN", "AuthLdapBindDn": "Bind DN",
@ -271,7 +267,7 @@
"BasePlatform": "Base platform", "BasePlatform": "Base platform",
"BasePort": "listening port", "BasePort": "listening port",
"Basic": "Basic", "Basic": "Basic",
"BasicInfo": "Basic info", "BasicInfo": "Basic information",
"BasicSetting": "Basic setting", "BasicSetting": "Basic setting",
"BasicTools": "Basic tool", "BasicTools": "Basic tool",
"BatchActivate": "Batch activate", "BatchActivate": "Batch activate",
@ -336,7 +332,7 @@
"ChangeViewHelpText": "Click to change view", "ChangeViewHelpText": "Click to change view",
"Charset": "Charset", "Charset": "Charset",
"Chat": "Chat", "Chat": "Chat",
"ChatAI": "Chat ai", "ChatAI": "Chat AI",
"ChatHello": "Hello! What help can I offer you?", "ChatHello": "Hello! What help can I offer you?",
"ChdirHelpText": "The default execution directory is the home directory of the executing user", "ChdirHelpText": "The default execution directory is the home directory of the executing user",
"CheckAssetsAmount": "Check assets amount", "CheckAssetsAmount": "Check assets amount",
@ -736,7 +732,7 @@
"GrantedK8Ss": "Granted K8Ss", "GrantedK8Ss": "Granted K8Ss",
"GrantedRemoteApps": "Granted remote apps", "GrantedRemoteApps": "Granted remote apps",
"GreatEqualThan": "Greater than or equal to", "GreatEqualThan": "Greater than or equal to",
"GroupsAmount": "Groups amount", "GroupsAmount": "Groups",
"GroupsHelpMessage": "Please fill in user groups, separated by commas if there are multiple user groups(Please fill in the existing user groups)", "GroupsHelpMessage": "Please fill in user groups, separated by commas if there are multiple user groups(Please fill in the existing user groups)",
"Guide": "Guide", "Guide": "Guide",
"HandleTicket": "Handle Ticket", "HandleTicket": "Handle Ticket",
@ -1524,7 +1520,7 @@
"SignaturesAndTemplates": "Signatures and Templates", "SignaturesAndTemplates": "Signatures and Templates",
"SiteMessage": "Site messages", "SiteMessage": "Site messages",
"SiteMessageList": "Site message", "SiteMessageList": "Site message",
"SiteUrl": "Current SITE URL", "SiteUrl": "Current Site URL",
"Skip": "Ignore current asset", "Skip": "Ignore current asset",
"Skipped": "Skipped", "Skipped": "Skipped",
"Slack": "Slack", "Slack": "Slack",
@ -1608,17 +1604,12 @@
"SystemSetting": "System setting", "SystemSetting": "System setting",
"SystemTools": "Tools", "SystemTools": "Tools",
"SystemUser": "System user", "SystemUser": "System user",
"SystemUserAmount": "SystemUser amount",
"SystemUserCount": "System user count",
"SystemUserCreate": "System user create",
"SystemUserDetail": "System user detail",
"SystemUserId": "SystemUser Id", "SystemUserId": "SystemUser Id",
"SystemUserList": "System Users", "SystemUserList": "System Users",
"SystemUserListHelpMessage": "<b>System user</b> is the account JumpServer used to log into the asset, such as using root `ssh root@host`, rather than the current user usernamessh admin@host)`;<br><b>Admin user</b> is the account that already exists on an asset, and have privileged permissions, JumpServer using this create common system user, and gather hardware Etc;</br><b>Common user</b> can pre-exist assets or created automatically by the admin user.", "SystemUserListHelpMessage": "<b>System user</b> is the account JumpServer used to log into the asset, such as using root `ssh root@host`, rather than the current user usernamessh admin@host)`;<br><b>Admin user</b> is the account that already exists on an asset, and have privileged permissions, JumpServer using this create common system user, and gather hardware Etc;</br><b>Common user</b> can pre-exist assets or created automatically by the admin user.",
"SystemUserName": "System username", "SystemUserName": "System username",
"SystemUserUpdate": "System user update", "SystemUserUpdate": "System user update",
"SystemUsers": "System users", "SystemUsers": "System users",
"SystemUsersAmount": "System users amount",
"SystemUsersNameGroup": "Systemuser name", "SystemUsersNameGroup": "Systemuser name",
"SystemUsersProtocolGroup": "Systemuser protocol", "SystemUsersProtocolGroup": "Systemuser protocol",
"SystemUsersUsernameGroup": "systemuser username", "SystemUsersUsernameGroup": "systemuser username",
@ -1738,7 +1729,7 @@
"UnselectedOrg": "Unselected org", "UnselectedOrg": "Unselected org",
"UnselectedUser": "Unselected user", "UnselectedUser": "Unselected user",
"UpDownload": "Upload download", "UpDownload": "Upload download",
"Update": "Update", "Update": "Edit",
"UpdateAccount": "Update account", "UpdateAccount": "Update account",
"UpdateAccountMsg": "Please update system user account info", "UpdateAccountMsg": "Please update system user account info",
"UpdateAccountTemplate": "Update account template", "UpdateAccountTemplate": "Update account template",
@ -1822,7 +1813,7 @@
"UsernameOfCreateUpdatePage": "The username of the user on the target host; If already existed, modify user password; If it doesn't exist, add the user and set the password.", "UsernameOfCreateUpdatePage": "The username of the user on the target host; If already existed, modify user password; If it doesn't exist, add the user and set the password.",
"UsernamePlaceholder": "Please input username", "UsernamePlaceholder": "Please input username",
"Users": "User", "Users": "User",
"UsersAmount": "Users amount", "UsersAmount": "Users",
"UsersAndUserGroups": "Users and user groups", "UsersAndUserGroups": "Users and user groups",
"UsersTotal": "Accounts total", "UsersTotal": "Accounts total",
"Valid": "Valid", "Valid": "Valid",

View File

@ -23,7 +23,7 @@ class AuthSettingSerializer(serializers.Serializer):
AUTH_PASSKEY = serializers.BooleanField(default=False, label=_("Passkey Auth")) AUTH_PASSKEY = serializers.BooleanField(default=False, label=_("Passkey Auth"))
FORGOT_PASSWORD_URL = serializers.CharField( FORGOT_PASSWORD_URL = serializers.CharField(
required=False, allow_blank=True, max_length=1024, required=False, allow_blank=True, max_length=1024,
label=_("Forgot password url") label=_("Forgot Password URL")
) )
LOGIN_REDIRECT_MSG_ENABLED = serializers.BooleanField( LOGIN_REDIRECT_MSG_ENABLED = serializers.BooleanField(
required=False, label=_("Enable login redirect msg") required=False, label=_("Enable login redirect msg")

View File

@ -13,7 +13,7 @@ class CommonSettingSerializer(serializers.Serializer):
# OpenID 公有配置参数 (version <= 1.5.8 或 version >= 1.5.8) # OpenID 公有配置参数 (version <= 1.5.8 或 version >= 1.5.8)
BASE_SITE_URL = serializers.CharField( BASE_SITE_URL = serializers.CharField(
required=False, allow_null=True, allow_blank=True, required=False, allow_null=True, allow_blank=True,
max_length=1024, label=_('Base site url') max_length=1024, label=_('Base site URL')
) )
AUTH_OPENID_CLIENT_ID = serializers.CharField( AUTH_OPENID_CLIENT_ID = serializers.CharField(
required=False, max_length=1024, label=_('Client Id') required=False, max_length=1024, label=_('Client Id')

View File

@ -8,7 +8,7 @@ class BasicSettingSerializer(serializers.Serializer):
PREFIX_TITLE = _('Basic') PREFIX_TITLE = _('Basic')
SITE_URL = serializers.URLField( SITE_URL = serializers.URLField(
required=True, label=_("Site url"), required=True, label=_("Site URL"),
help_text=_( help_text=_(
'External URL, email links or other system callbacks are used to access it, ' 'External URL, email links or other system callbacks are used to access it, '
'eg: http://dev.jumpserver.org:8080' 'eg: http://dev.jumpserver.org:8080'
@ -19,7 +19,7 @@ class BasicSettingSerializer(serializers.Serializer):
help_text=_('User first login update profile done redirect to it') help_text=_('User first login update profile done redirect to it')
) )
GLOBAL_ORG_DISPLAY_NAME = serializers.CharField( GLOBAL_ORG_DISPLAY_NAME = serializers.CharField(
required=False, max_length=1024, allow_blank=True, allow_null=True, label=_("Global organization name"), required=False, max_length=1024, allow_blank=True, allow_null=True, label=_("Global organization"),
help_text=_('The name of global organization to display') help_text=_('The name of global organization to display')
) )
HELP_DOCUMENT_URL = serializers.URLField( HELP_DOCUMENT_URL = serializers.URLField(

View File

@ -19,7 +19,7 @@ class AnnouncementSerializer(serializers.Serializer):
CONTENT = serializers.CharField(label=_("Content")) CONTENT = serializers.CharField(label=_("Content"))
LINK = serializers.URLField( LINK = serializers.URLField(
required=False, allow_null=True, allow_blank=True, required=False, allow_null=True, allow_blank=True,
label=_("More url"), default='', label=_("More URL"), default='',
) )
def to_representation(self, instance): def to_representation(self, instance):
@ -75,7 +75,7 @@ class ChatAISettingSerializer(serializers.Serializer):
required=False, label=_('Enable Chat AI') required=False, label=_('Enable Chat AI')
) )
GPT_BASE_URL = serializers.CharField( GPT_BASE_URL = serializers.CharField(
max_length=256, allow_blank=True, required=False, label=_('Base Url') max_length=256, allow_blank=True, required=False, label=_('Base URL')
) )
GPT_API_KEY = EncryptedField( GPT_API_KEY = EncryptedField(
max_length=256, allow_blank=True, required=False, label=_('API Key'), max_length=256, allow_blank=True, required=False, label=_('API Key'),