feat(i18n): 全量中英文国际化改造
- 翻译 en-US.json 中 1006 条未翻译的中文条目为英文 - 提取 30+ 组件文件的硬编码中文到 locale JSON - 新增 900+ 翻译键覆盖所有业务模块: - Layout (Sidebar, Header, Breadcrumb) - Server (ServerForm, CloudServerImport, WebShell, RdpTools) - Deploy (ReleaseManager, PipelineCreate, AppRelease) - Kubernetes (DeploymentEdit, PodExec, PodLogs, ResourceEditor) - Monitor (UnifiedQueryPanel, AlertCenter, Prometheus/Grafana Dashboard) - AIOps (predictUtils, PredictiveCostTab, AIPredictive) - System (useLdapManagement, AgentMonitor, AgentWizard) - tsc --noEmit 类型检查通过
This commit is contained in:
1 parent
76ec9387f0
commit
a9513c2056
44 files changed
+4342
-1792
No files matched your search
@@ -146,9 +146,9 @@ export function useLdapManagement(onUsersChanged: () => Promise<void> | void) {
|
||||
} catch (e) {
|
||||
const msg = e?.message || '';
|
||||
if (msg.includes('Already Exists') || msg.includes('68')) {
|
||||
toast.error(`OU "${ouForm.ou_name}" 已存在,请使用其他名称`);
|
||||
toast.error(i18n.t('system.useldapmanageme.s1a2b3c4d', { name: ouForm.ou_name }));
|
||||
} else {
|
||||
toast.error(i18n.t('system.useldapmanageme.sa2bddca3') + msg);
|
||||
toast.error(i18n.t('system.useldapmanageme.s2b3c4d5e') + msg);
|
||||
}
|
||||
} finally { setLdapSaving(false); }
|
||||
};
|
||||
@@ -252,7 +252,7 @@ export function useLdapManagement(onUsersChanged: () => Promise<void> | void) {
|
||||
email: u.mail || '',
|
||||
}));
|
||||
const res = await ldapApi.batchImport(mapped);
|
||||
const message = (res as JsonData)?.message || `成功导入 ${selected.length} 个用户`;
|
||||
const message = (res as JsonData)?.message || i18n.t('system.importSuccess') + `: ${selected.length}`;
|
||||
const result = { code: 200, message };
|
||||
if (opts?.setResult) {
|
||||
opts.setResult(result);
|
||||
|
||||
Reference in new issue
Block a user