Skip to content

Commit 12c727f

Browse files
authored
refactor(api, external/error): update translations (#138)
1 parent bdb6ee1 commit 12c727f

File tree

7 files changed

+48
-9
lines changed

7 files changed

+48
-9
lines changed

apps/main/[4]task/components/TaskTable/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ function getColumns(
164164
valueEnum: {
165165
cluster: { text: t('model:task.bizType.cluster') },
166166
host: { text: t('model:task.bizType.host') },
167+
checkReport: { text: t('model:task.bizType.checkReport') },
167168
},
168169
},
169170
{

external/error/input.csv

Lines changed: 39 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -77,11 +77,16 @@ backup record invalid",备份记录无效,400,,
7777
","工作流等待超时(参见workflow错误码40105)
7878
",500,,
7979
,克隆集群-209xx,20900,The version of clone cluster must be higher than current cluster ,克隆集群版本必须高于现有集群,409,,
80-
,主备管理-210xx,,,,,,
80+
,主备管理-210xx,21000,Master slave relation not found,主备集群不存在,404,,
81+
,,21001,Master slave switchover failed,主备集群切换失败,500,,
82+
,,21002,Master slave CDC sync task not found,主备集群CDC同步任务未建立,400,,
83+
,,21003,Slave has no CDC component,备集群未部署CDC组件,400,,
8184
,集群原地升级-211xx,21100,Upgrade path doesn't exist,升级路径不存在,404,,
8285
,,21101,Upgrade software package doesn't exist,升级软件包不存在,404,,
8386
,,21102,Not support to downgrade cluster version,不支持降级集群版本,409,,
8487
,,21103,Failed to in-place upgrade ,原地升级失败,500,,
88+
,,21104,Regions are not fully healthy,存在 Region 不健康,如 miss peer 或 pending peer,,,
89+
,,21105,Upgrade version incorrect,升级后版本信息有误,,,
8590
,集群同步-212xx,21201,Change feed task is not found,任务不存在,404,,
8691
,,21202,Duplicate id,任务重复,,,
8792
,,21203,Task status conflict,任务变更中,不允许操作,409,,
@@ -116,12 +121,27 @@ backup record invalid",备份记录无效,400,,
116121
,,30123,Decrypt password failed,解密主机密码失败,,,
117122
,,30124,Allocate Resource failed,资源分配失败,,,
118123
,,30125,Recycle Resource failed,资源回收失败,,,
119-
,,30126,connect to host failed,(导入主机前检查)连接主机失败,400,,
120-
,,30127,new connect session to host failed,(导入主机前检查)主机创建session连接失败,500,,
121-
,,30128,run command on host failed,(导入主机前检查)远程主机运行命令失败,500,,
122-
,,30129,host is not expected as import file,主机和导入模板参数不一致,400,,
123-
,,30130,install filebeat on host failed,导入主机安装filebeat失败,400,,
124-
,,30131,extract workflow context failed,(内部)获取上下文失败,,,
124+
,,30126,Connect to host failed,(导入主机前检查)连接主机失败,400,,
125+
,,30127,New connect session to host failed,(导入主机前检查)主机创建session连接失败,500,,
126+
,,30128,Run command on host failed,(导入主机前检查)远程主机运行命令失败,500,,
127+
,,30129,Host is not expected as import file,主机和导入模板参数不一致,400,,
128+
,,30130,Install filebeat on host failed,导入主机安装filebeat失败,400,,
129+
,,30131,Extract workflow context failed,(内部)获取上下文失败,,,
130+
,,30132,Uninstall filebeat on host failed,删除主机时卸载filebeat失败,400,删除一个Fail状态的主机请带上force=true,因为Fail状态的主机一般是还没部署filebeat,
131+
,,30133,Prepare host before verify failed,初始化主机失败,500,,
132+
,,30134,Invalid vendor,无效的厂商ID(暂时没有用到),400,"通过xlsx导入的主机Vendor
133+
都为""Local""",
134+
,,30135,Invalid zone info,导入的主机位置信息不合法,400,,
135+
,,30136,check compute resource mismatch,巡检计算资源不一致,500,巡检发现资源侧和集群侧占用的主机cpu/memory不一致,
136+
,,30137,check disk resource mismatch,巡检磁盘信息不一致,500,,
137+
,,30138,init deploy user failed,创建部署用户失败,500,导入主机创建tidb用户失败,
138+
,,30139,init host auth failed,创建免密失败,500,导入主机建立免密失败,
139+
,,30140,update host info failed,更新主机失败,400,更新主机信息的api返回错误,
140+
,,30141,validate disk info failed,校验磁盘信息失败,400,导入主机文件里的disk json或者更新磁盘api的磁盘信息不对,
141+
,,30142,update disk failed,更新磁盘失败,500,,
142+
,,30143,delete disk failed,删除磁盘失败,500,,
143+
,,30144,disk is still in used,磁盘正在使用中,409,删除磁盘时检查到磁盘还在使用中,
144+
,,30145,disk is already existed,磁盘已存在,409,重复增加磁盘(diskName+path作为标识),
125145
,,,,,,,
126146
工作流管理-4xxxx,工作流管理-401xx,40100,workflow create failed,创建工作流失败,500,,
127147
,,40101,workflow query failed,查询工作流列表失败,500,,
@@ -155,6 +175,18 @@ TiEM平台管理-7xxxx,TiEM升级-701xx,70100,,,,,
155175
,,70601,User is not found,用户不存在,404,给用户管理模块预留,暂时不会出现,
156176
,,70602,Access token has been expired,用户 Token 已经失效,401,,
157177
,,70603,Incorrect username or password,用户名或密码错误,400,,
178+
,,,,,,,
179+
,,70650,"
180+
rbac permission check failed",RBAC权限校验失败,403,,
181+
,,70651,rbac permission add failed,RBAC权限添加失败,500,,
182+
,,70652,rbac permission delete failed,RBAC权限删除失败,500,,
183+
,,70653,rbac permission query failed,RBAC权限查询失败,500,,
184+
,,70654,rbac role create failed,RBAC角色创建失败,500,,
185+
,,70655,rbac role query failed,RBAC角色查询失败,500,,
186+
,,70656,rbac role delete failed,RBAC角色删除失败,500,,
187+
,,70657,rbac role bind user failed,RBAC角色绑定失败,500,,
188+
,,70658,rbac role unbind user failed,RBAC角色解绑失败,500,,
189+
,,,,,,,
158190
集群监控告警日志-8xxxx,集群监控-801xx,80100,dashboard is not found,未找到dashboard,,,
159191
,,80101,TIEM_MONITOR_NOT_FOUND,未找到监控页面,,,
160192
,集群告警-802xx,,,,,,

src/api/model/translations/en.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,7 @@ task:
288288
bizType:
289289
cluster: Cluster
290290
host: Host
291+
checkReport: Inspection Report
291292
operator:
292293
system: System Automation
293294
knowledge:

src/api/model/translations/zh.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -288,6 +288,7 @@ task:
288288
bizType:
289289
cluster: 集群
290290
host: 主机
291+
checkReport: 巡检报告
291292
operator:
292293
system: 系统自动
293294
knowledge:

src/api/task/translations/en.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,5 @@ name:
2424
SwitchoverNormal: Master-Standby Cluster Switchover
2525
SwitchoverForce: Master-Standby Cluster Forced Switchover
2626
SwitchoverForceWithMasterUnavailable: Master-Standby Cluster Forced Switchover
27+
CheckPlatform: Platform Inspection
28+
CheckCluster: Cluster Inspection

src/api/task/translations/zh.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,5 @@ name:
2424
SwitchoverNormal: 切换主备集群
2525
SwitchoverForce: 强制切换主备集群
2626
SwitchoverForceWithMasterUnavailable: 强制切换主备集群
27+
CheckPlatform: 平台巡检
28+
CheckCluster: 集群巡检

vite.config.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ export default defineConfig(({ mode }) => {
3838
vitePluginHtml({
3939
inject: {
4040
injectData: {
41-
title: env.VITE_TITLE || 'TiCP Demo',
42-
description: env.VITE_DESCRIPTION || 'Just a demo now.',
41+
title: env.VITE_TITLE || 'TiEM',
42+
description: env.VITE_DESCRIPTION || 'TiDB Enterprise Manager',
4343
},
4444
},
4545
minify: true,

0 commit comments

Comments
 (0)