Skip to content

Commit

Permalink
minor: 后端国际化补充
Browse files Browse the repository at this point in the history
  • Loading branch information
normal-wls committed Jun 28, 2023
1 parent c11ceac commit 2ae014b
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 19 deletions.
16 changes: 4 additions & 12 deletions gcloud/taskflow3/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,22 +51,14 @@
from gcloud.project_constants.domains.context import get_project_constants_context
from gcloud.shortcuts.cmdb import get_business_attrinfo, get_business_group_members
from gcloud.taskflow3.domains.context import TaskContext
from gcloud.taskflow3.domains.dispatchers import (
NodeCommandDispatcher,
TaskCommandDispatcher,
)
from gcloud.taskflow3.domains.dispatchers import NodeCommandDispatcher, TaskCommandDispatcher
from gcloud.taskflow3.utils import parse_node_timeout_configs
from gcloud.tasktmpl3.models import TaskTemplate
from gcloud.template_base.utils import inject_original_template_info, inject_template_node_id, replace_template_id
from gcloud.utils.components import (
format_component_name_with_remote,
get_remote_plugin_name,
)
from gcloud.utils.components import format_component_name_with_remote, get_remote_plugin_name
from gcloud.utils.dates import format_datetime, timestamp_to_datetime
from gcloud.utils.managermixins import ClassificationCountMixin
from pipeline_plugins.components.collections.subprocess_plugin.converter import (
PipelineTreeSubprocessConverter,
)
from pipeline_plugins.components.collections.subprocess_plugin.converter import PipelineTreeSubprocessConverter
from pipeline_web.core.abstract import NodeAttr
from pipeline_web.core.models import NodeInInstance
from pipeline_web.parser.clean import PipelineWebTreeCleaner
Expand Down Expand Up @@ -539,7 +531,7 @@ def group_by_instance_biz(self, taskflow, filters, page, limit):
)
proj_dimension_dict = dict(
ProjectStatisticsDimension.objects.values_list("dimension_id", "dimension_name")
) or {"bk_biz_name": "业务"}
) or {"bk_biz_name": _("业务")}
proj_dimension_id_list = proj_dimension_dict.keys()
# 获取全部业务对应维度信息
total = len(proj_dimension_id_list)
Expand Down
Binary file modified locale/en/LC_MESSAGES/django.mo
Binary file not shown.
14 changes: 7 additions & 7 deletions locale/en/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -76,11 +76,11 @@ msgstr "Others"

#: gcloud/constants.py:40
msgid "默认分类"
msgstr "default Category"
msgstr "Default"

#: gcloud/constants.py:45
msgid "默认任务流程"
msgstr "Default Task Flow"
msgstr "General Task"

#: gcloud/constants.py:46
msgid "职能化任务流程"
Expand Down Expand Up @@ -273,7 +273,7 @@ msgstr "Project ID"
#: gcloud/contrib/appmaker/models.py:270 gcloud/template_base/models.py:232
#: gcloud/user_custom_config/constants.py:20
msgid "模板类型"
msgstr "Template Type"
msgstr "Category"

#: gcloud/analysis_statistics/models.py:27
#: gcloud/analysis_statistics/models.py:50 pipeline_web/core/abstract.py:19
Expand Down Expand Up @@ -409,7 +409,7 @@ msgstr "Gateways Count"
#: gcloud/taskflow3/models.py:1336 gcloud/user_custom_config/constants.py:18
#: pipeline_web/core/abstract.py:21
msgid "创建时间"
msgstr "Created Time"
msgstr "Created At"

#: gcloud/analysis_statistics/models.py:88 gcloud/core/models.py:150
msgid "最近编辑时间"
Expand Down Expand Up @@ -482,7 +482,7 @@ msgstr "Common Template"
#: gcloud/conf/sites/community/ver_settings.py:20
#: gcloud/conf/sites/enterprise/ver_settings.py:20
msgid "腾讯蓝鲸智云"
msgstr "Tencent Blueking"
msgstr "Tencent BlueKing"

#: gcloud/contrib/appmaker/api.py:56
msgid "轻应用保存失败: 非法的图片格式, 请使用不超过100KB的JPG / PNG 图片作为应用LOGO | appmaker save"
Expand Down Expand Up @@ -1640,7 +1640,7 @@ msgstr "Updater"
#: gcloud/project_constants/models.py:30
#: gcloud/user_custom_config/constants.py:19
msgid "更新时间"
msgstr "Update Time"
msgstr "Modified At"

#: gcloud/shortcuts/message/common.py:20
msgid "【标准运维APP通知】执行失败"
Expand Down Expand Up @@ -1936,7 +1936,7 @@ msgstr "Failed to delete the flow: the flow has been referenced by other cron ta

#: gcloud/user_custom_config/constants.py:17
msgid "模板ID"
msgstr "Template ID"
msgstr "ID"

#: gcloud/user_custom_config/models.py:45
msgid "所属项目ID"
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@ exclude = '''
| dist
)/
'''
[tool.isort]
line_length = 120

0 comments on commit 2ae014b

Please sign in to comment.