refactor(i18n): U17 K8s 残余组件 i18n 补全 — NodeDetailPage 16 处硬编码中文清零 + 8 个 hash 键替换为语义化 k8s.nodeDetail.* + DeploymentWorkload 12 处 toast/confirm 硬编码中文清零. 新增 k8s.nodeDetail 命名空间 21 键 + k8s.deploymentDetail 扩展 12 键(含插值). zh/en 7564→7597 对齐. 组件从 i18n.t() 全局改为 useTranslation() hook. tsc -b=0, npm build✓, ESLint=0, 17/17 测试通过
This commit is contained in:
1 parent
a85e063a47
commit
be1011eb58
5 files changed
+129
-57
No files matched your search
@@ -162,7 +162,7 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
setActionLoading('scale');
|
||||
try {
|
||||
await kubernetesApi.scaleDeployment(clusterCode, namespace, deploymentName, newReplicas);
|
||||
toast({ title: i18n.t('k8s.workloads.scaleSuccess'), description: `副本数已设置为 ${newReplicas}` });
|
||||
toast({ title: i18n.t('k8s.workloads.scaleSuccess'), description: i18n.t('k8s.deploymentDetail.replicasSetTo', { count: newReplicas }) });
|
||||
loadData();
|
||||
} catch (e) {
|
||||
toast({ title: i18n.t('cloud.operationFailed'), description: e?.message || String(e), variant: 'destructive' });
|
||||
@@ -173,7 +173,7 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
setActionLoading('scale');
|
||||
try {
|
||||
await kubernetesApi.scaleDeployment(clusterCode, namespace, deploymentName, scaleValue);
|
||||
toast({ title: i18n.t('kubernetes.msg.scaleSuccess'), description: `副本数已设置为 ${scaleValue}` });
|
||||
toast({ title: i18n.t('kubernetes.msg.scaleSuccess'), description: i18n.t('k8s.deploymentDetail.replicasSetTo', { count: scaleValue }) });
|
||||
setModal(null);
|
||||
loadData();
|
||||
} catch (e) {
|
||||
@@ -184,7 +184,7 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
const handleRestart = async () => {
|
||||
const ok = await confirm({
|
||||
title: i18n.t('kubernetes.deployment.restart'),
|
||||
description: `确认滚动重启 Deployment "${deploymentName}"?`,
|
||||
description: i18n.t('k8s.deploymentDetail.confirmRestart', { name: deploymentName }),
|
||||
confirmText: i18n.t('agent.agentServiceRestart'),
|
||||
});
|
||||
if (!ok) return;
|
||||
@@ -202,8 +202,8 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
const isPaused = !!deployment?.paused;
|
||||
const action = isPaused ? i18n.t('kubernetes.deployment.resume') : i18n.t('kubernetes.job.suspend');
|
||||
const ok = await confirm({
|
||||
title: `${action}滚动更新`,
|
||||
description: `确认${action} Deployment "${deploymentName}" 的滚动更新?`,
|
||||
title: i18n.t('k8s.deploymentDetail.rollingUpdate', { action }),
|
||||
description: i18n.t('k8s.deploymentDetail.confirmRollingUpdate', { action, name: deploymentName }),
|
||||
confirmText: action,
|
||||
});
|
||||
if (!ok) return;
|
||||
@@ -214,10 +214,10 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
} else {
|
||||
await kubernetesApi.pauseDeployment(clusterCode, namespace, deploymentName);
|
||||
}
|
||||
toast({ title: `${action}成功`, description: `Deployment 滚动更新已${action}` });
|
||||
toast({ title: i18n.t('k8s.deploymentDetail.actionSuccess', { action }), description: i18n.t('k8s.deploymentDetail.rollingUpdated', { action }) });
|
||||
setTimeout(loadData, 1000);
|
||||
} catch (e) {
|
||||
toast({ title: `${action}失败`, description: e?.message || String(e), variant: 'destructive' });
|
||||
toast({ title: i18n.t('k8s.deploymentDetail.actionFailed', { action }), description: e?.message || String(e), variant: 'destructive' });
|
||||
} finally { setActionLoading(''); }
|
||||
};
|
||||
|
||||
@@ -234,7 +234,7 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
await kubernetesApi.updateDeploymentImage(
|
||||
clusterCode, namespace, deploymentName, newImage, cicdContainerName || undefined,
|
||||
);
|
||||
toast({ title: i18n.t('kubernetes.deploymentdetai.s6df3c303'), description: `正在滚动更新为 ${newImage}` });
|
||||
toast({ title: i18n.t('kubernetes.deploymentdetai.s6df3c303'), description: i18n.t('k8s.deploymentDetail.rollingUpdateImage', { image: newImage }) });
|
||||
setModal(null);
|
||||
loadData();
|
||||
} catch (e) {
|
||||
@@ -251,7 +251,7 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
const url = `${baseUrl}/api/v1/kubernetes/${clusterCode}/namespace/${namespace}/deployments/${deploymentName}`;
|
||||
const resp = await fetch(url, { method: 'DELETE', headers: { Authorization: `Bearer ${tk}` } });
|
||||
if (!resp.ok) throw new Error(`HTTP ${resp.status}`);
|
||||
toast({ title: i18n.t('kubernetes.msg.deleteSuccess'), description: `${deploymentName} 已删除` });
|
||||
toast({ title: i18n.t('kubernetes.msg.deleteSuccess'), description: i18n.t('k8s.deploymentDetail.deploymentDeleted', { name: deploymentName }) });
|
||||
setModal(null);
|
||||
setTimeout(() => navigate(`/kubernetes/${clusterCode}/namespace/${namespace}/deployments`), 800);
|
||||
} catch (e) {
|
||||
@@ -272,7 +272,7 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
const handleDeletePod = async (pod: any) => {
|
||||
const ok = await confirm({
|
||||
title: i18n.t('kubernetes.pod.deletePod'),
|
||||
description: `确认删除 Pod "${pod.name}"?操作不可恢复。`,
|
||||
description: i18n.t('k8s.deploymentDetail.confirmDeletePod', { name: pod.name }),
|
||||
confirmText: i18n.t('kubernetes.storage.delete2'),
|
||||
});
|
||||
if (!ok) return;
|
||||
@@ -297,7 +297,7 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
if (!deployment && !isCreate) {
|
||||
return (
|
||||
<PageShell variant="default" title={deploymentName} subtitle={`${clusterCode} / ${namespace}`} actions={<Button variant="outline" size="sm" className="dg-btn-secondary" onClick={onBack}><ArrowLeft className="h-4 w-4 mr-1" /> {i18n.t('common.back')} </Button>}>
|
||||
<Card className="dg-card"><CardContent className="p-12 text-center"><XCircle className="h-8 w-8 mx-auto dg-text-red" /><p className="dg-text-secondary mt-3">未找到 Deployment: {deploymentName}</p></CardContent></Card>
|
||||
<Card className="dg-card"><CardContent className="p-12 text-center"><XCircle className="h-8 w-8 mx-auto dg-text-red" /><p className="dg-text-secondary mt-3">{i18n.t('k8s.deploymentDetail.deploymentNotFound', { name: deploymentName })}</p></CardContent></Card>
|
||||
</PageShell>
|
||||
);
|
||||
}
|
||||
@@ -330,7 +330,7 @@ export function DeploymentWorkload({ clusterCode, namespace, deploymentName, mod
|
||||
<PageShell
|
||||
variant="workspace"
|
||||
title={deploymentName}
|
||||
subtitle={`${clusterCode} / ${namespace} · Deployment · 镜像: ${deployment?.image || '-'}`}
|
||||
subtitle={`${clusterCode} / ${namespace} · Deployment · ${i18n.t('k8s.deploymentDetail.imageLabel')}: ${deployment?.image || '-'}`}
|
||||
actions={(
|
||||
<>
|
||||
<Button variant="outline" size="sm" className="dg-btn-secondary" onClick={onBack}><ArrowLeft className="h-4 w-4 mr-1" /> {i18n.t('common.back')} </Button>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
/* eslint-disable @typescript-eslint/no-explicit-any */
|
||||
import { useState, useEffect, useCallback } from 'react';
|
||||
import { useParams, useNavigate } from 'react-router-dom';
|
||||
import { useTranslation } from 'react-i18next';
|
||||
import { Card, CardContent } from '@/components/ui/card';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { Badge } from '@/components/ui/badge';
|
||||
@@ -8,7 +9,7 @@ import {
|
||||
Table, TableBody, TableCell, TableHead, TableHeader, TableRow,
|
||||
} from '@/components/ui/table';
|
||||
import {
|
||||
|
||||
|
||||
RefreshCw,
|
||||
Server,
|
||||
Activity,
|
||||
@@ -22,9 +23,9 @@ import {
|
||||
|
||||
import { kubernetesApi } from '@/api';
|
||||
import { PageShell } from '@/components/layout/PageShell';
|
||||
import i18n from '@/i18n';
|
||||
|
||||
export default function NodeDetailPage() {
|
||||
const { t } = useTranslation();
|
||||
const { clusterCode, nodeName } = useParams<{ clusterCode: string; nodeName: string }>();
|
||||
const navigate = useNavigate();
|
||||
const [data, setData] = useState<any>(null);
|
||||
@@ -96,20 +97,20 @@ export default function NodeDetailPage() {
|
||||
return (
|
||||
<PageShell
|
||||
variant="default"
|
||||
title={nodeName || i18n.t('kubernetes.nodedetailpaget.sb88b9847')}
|
||||
title={nodeName || t('k8s.nodeDetail.nodeTitle')}
|
||||
subtitle={nodeSubtitle || clusterCode}
|
||||
icon={<Server className="h-5 w-5" />}
|
||||
loading={loading && !data}
|
||||
loadingLabel={i18n.t('kubernetes.nodedetailpaget.sfdff6194')}
|
||||
loadingLabel={t('k8s.nodeDetail.loadingNode')}
|
||||
actions={(
|
||||
<>
|
||||
<Button variant="outline" size="sm" className="dg-btn-secondary" onClick={() => navigate(-1)}>
|
||||
<ArrowLeft className="h-4 w-4 mr-1" />
|
||||
返回
|
||||
{t('common.back')}
|
||||
</Button>
|
||||
<Button variant="outline" size="sm" className="dg-btn-secondary" onClick={loadData} disabled={loading}>
|
||||
<RefreshCw className={`h-4 w-4 mr-1 ${loading ? 'animate-spin' : ''}`} />
|
||||
刷新
|
||||
{t('common.refresh')}
|
||||
</Button>
|
||||
</>
|
||||
)}
|
||||
@@ -129,7 +130,7 @@ export default function NodeDetailPage() {
|
||||
<Card className="dg-card">
|
||||
<CardContent className="py-16 text-center dg-text-muted">
|
||||
<AlertTriangle className="h-8 w-8 mx-auto mb-2 opacity-50" />
|
||||
无法加载节点详情
|
||||
{t('k8s.nodeDetail.loadFailed')}
|
||||
</CardContent>
|
||||
</Card>
|
||||
) : data ? (
|
||||
@@ -140,11 +141,11 @@ export default function NodeDetailPage() {
|
||||
<Card className="dg-card">
|
||||
<CardContent className="p-4">
|
||||
<h2 className="text-sm font-semibold text-[var(--dg-text-primary)] mb-3 flex items-center gap-2">
|
||||
<Info className="h-4 w-4 dg-text-cyan" />系统信息
|
||||
<Info className="h-4 w-4 dg-text-cyan" />{t('k8s.nodeDetail.systemInfo')}
|
||||
</h2>
|
||||
<div className="space-y-2 text-xs">
|
||||
<div className="flex items-center justify-between py-1.5 border-b border-[var(--dg-border)]/50">
|
||||
<span className="dg-text-muted"> {i18n.t('kubernetes.node.containerRuntime')} </span>
|
||||
<span className="dg-text-muted"> {t('kubernetes.node.containerRuntime')} </span>
|
||||
<span className="text-[var(--dg-text-secondary)] font-mono">{data.container_runtime || '-'}</span>
|
||||
</div>
|
||||
<div className="flex items-center justify-between py-1.5 border-b border-[var(--dg-border)]/50">
|
||||
@@ -152,19 +153,19 @@ export default function NodeDetailPage() {
|
||||
<span className="text-[var(--dg-text-secondary)] font-mono">{data.kubelet_version || '-'}</span>
|
||||
</div>
|
||||
<div className="flex items-center justify-between py-1.5 border-b border-[var(--dg-border)]/50">
|
||||
<span className="dg-text-muted"> {i18n.t('agent.agentOs')} </span>
|
||||
<span className="dg-text-muted"> {t('agent.agentOs')} </span>
|
||||
<span className="text-[var(--dg-text-secondary)]">{data.os_image || '-'}</span>
|
||||
</div>
|
||||
<div className="flex items-center justify-between py-1.5 border-b border-[var(--dg-border)]/50">
|
||||
<span className="dg-text-muted"> {i18n.t('kubernetes.node.kernelVersion')} </span>
|
||||
<span className="dg-text-muted"> {t('kubernetes.node.kernelVersion')} </span>
|
||||
<span className="text-[var(--dg-text-secondary)] font-mono">{data.kernel_version || '-'}</span>
|
||||
</div>
|
||||
<div className="flex items-center justify-between py-1.5 border-b border-[var(--dg-border)]/50">
|
||||
<span className="dg-text-muted"> {i18n.t('agent.agentArch')} </span>
|
||||
<span className="dg-text-muted"> {t('agent.agentArch')} </span>
|
||||
<span className="text-[var(--dg-text-secondary)] font-mono">{data.architecture || '-'}</span>
|
||||
</div>
|
||||
<div className="flex items-center justify-between py-1.5 border-b border-[var(--dg-border)]/50">
|
||||
<span className="dg-text-muted"> {i18n.t('system.userCreatedAt')} </span>
|
||||
<span className="dg-text-muted"> {t('system.userCreatedAt')} </span>
|
||||
<span className="text-[var(--dg-text-secondary)]">{data.creation_time ? new Date(data.creation_time).toLocaleString('zh-CN') : '-'}</span>
|
||||
</div>
|
||||
<div className="flex items-center justify-between py-1.5">
|
||||
@@ -179,14 +180,14 @@ export default function NodeDetailPage() {
|
||||
<Card className="dg-card">
|
||||
<CardContent className="p-4">
|
||||
<h2 className="text-sm font-semibold text-[var(--dg-text-primary)] mb-3 flex items-center gap-2">
|
||||
<Activity className="h-4 w-4 dg-text-green" />资源分配率
|
||||
<Activity className="h-4 w-4 dg-text-green" />{t('k8s.nodeDetail.resourceAllocation')}
|
||||
</h2>
|
||||
<div className="space-y-4 mt-4">
|
||||
{/* CPU allocation (requested vs allocatable) */}
|
||||
<ResourceBar
|
||||
label={i18n.t('kubernetes.nodedetailpaget.s7c390016')}
|
||||
used={`${(data.cpu_request_m / 1000).toFixed(2)} 核`}
|
||||
total={`${data.cpu_allocatable} 核`}
|
||||
label={t('k8s.nodeDetail.cpuAllocated')}
|
||||
used={`${(data.cpu_request_m / 1000).toFixed(2)} ${t('k8s.nodeDetail.coreUnit')}`}
|
||||
total={`${data.cpu_allocatable} ${t('k8s.nodeDetail.coreUnit')}`}
|
||||
unit=""
|
||||
pct={data.cpu_alloc_pct}
|
||||
color="dg-text-green"
|
||||
@@ -194,9 +195,9 @@ export default function NodeDetailPage() {
|
||||
{/* CPU real usage (from metrics) */}
|
||||
{data.cpu_usage_m && (
|
||||
<ResourceBar
|
||||
label={i18n.t('kubernetes.nodedetailpaget.s1ce99635')}
|
||||
label={t('k8s.nodeDetail.cpuRealtimeUsage')}
|
||||
used={data.cpu_usage_m}
|
||||
total={`${data.cpu_capacity} 核`}
|
||||
total={`${data.cpu_capacity} ${t('k8s.nodeDetail.coreUnit')}`}
|
||||
unit=""
|
||||
pct={(parseFloat(data.cpu_usage_m.replace('m', '')) / (data.cpu_capacity * 1000)) * 100}
|
||||
color="dg-text-blue"
|
||||
@@ -204,7 +205,7 @@ export default function NodeDetailPage() {
|
||||
)}
|
||||
{/* Memory allocation */}
|
||||
<ResourceBar
|
||||
label={i18n.t('kubernetes.nodedetailpaget.sccf1cf7a')}
|
||||
label={t('k8s.nodeDetail.memAllocated')}
|
||||
used={`${data.mem_request_mi} Mi`}
|
||||
total={`${data.mem_allocatable_mb} Mi`}
|
||||
unit=""
|
||||
@@ -214,7 +215,7 @@ export default function NodeDetailPage() {
|
||||
{/* Memory real usage */}
|
||||
{data.mem_usage_mi && (
|
||||
<ResourceBar
|
||||
label={i18n.t('kubernetes.nodedetailpaget.s841b8a96')}
|
||||
label={t('k8s.nodeDetail.memRealtimeUsage')}
|
||||
used={data.mem_usage_mi}
|
||||
total={`${data.mem_capacity_mb} Mi`}
|
||||
unit=""
|
||||
@@ -224,7 +225,7 @@ export default function NodeDetailPage() {
|
||||
)}
|
||||
{/* Pod allocation */}
|
||||
<ResourceBar
|
||||
label={i18n.t('kubernetes.nodedetailpaget.s55edf286')}
|
||||
label={t('k8s.nodeDetail.podCount')}
|
||||
used={`${data.pod_count}`}
|
||||
total={`${data.pod_allocatable}`}
|
||||
unit=""
|
||||
@@ -235,15 +236,15 @@ export default function NodeDetailPage() {
|
||||
{/* Capacity vs Allocatable raw */}
|
||||
<div className="mt-4 pt-3 border-t border-[var(--dg-border)]/50 space-y-1 text-[11px] dg-text-muted">
|
||||
<div className="flex justify-between">
|
||||
<span>CPU 容量 / 可分配</span>
|
||||
<span className="font-mono">{data.cpu_capacity} / {data.cpu_allocatable} 核</span>
|
||||
<span>{t('k8s.nodeDetail.cpuCapacityAlloc')}</span>
|
||||
<span className="font-mono">{data.cpu_capacity} / {data.cpu_allocatable} {t('k8s.nodeDetail.coreUnit')}</span>
|
||||
</div>
|
||||
<div className="flex justify-between">
|
||||
<span> {i18n.t('kubernetes.nodedetailpaget.s5038523b')} </span>
|
||||
<span> {t('k8s.nodeDetail.memCapacityAlloc')} </span>
|
||||
<span className="font-mono">{data.mem_capacity_mb} / {data.mem_allocatable_mb} Mi</span>
|
||||
</div>
|
||||
<div className="flex justify-between">
|
||||
<span>Pod 容量 / 可分配</span>
|
||||
<span>{t('k8s.nodeDetail.podCapacityAlloc')}</span>
|
||||
<span className="font-mono">{data.pod_capacity} / {data.pod_allocatable}</span>
|
||||
</div>
|
||||
</div>
|
||||
@@ -257,10 +258,10 @@ export default function NodeDetailPage() {
|
||||
<Card className="dg-card">
|
||||
<CardContent className="p-4">
|
||||
<h2 className="text-sm font-semibold text-[var(--dg-text-primary)] mb-3 flex items-center gap-2">
|
||||
<CheckCircle2 className="h-4 w-4 dg-text-blue" />节点条件
|
||||
<CheckCircle2 className="h-4 w-4 dg-text-blue" />{t('k8s.nodeDetail.conditions')}
|
||||
</h2>
|
||||
{(!data.conditions || data.conditions.length === 0) ? (
|
||||
<p className="text-xs dg-text-muted py-4 text-center"> {i18n.t('kubernetes.nodedetailpaget.s0f03f9da')} </p>
|
||||
<p className="text-xs dg-text-muted py-4 text-center"> {t('k8s.nodeDetail.noConditions')} </p>
|
||||
) : (
|
||||
<div className="space-y-2">
|
||||
{data.conditions.map(( cond: any, i: number) => (
|
||||
@@ -284,17 +285,17 @@ export default function NodeDetailPage() {
|
||||
<Card className="dg-card">
|
||||
<CardContent className="p-4">
|
||||
<h2 className="text-sm font-semibold text-[var(--dg-text-primary)] mb-3 flex items-center gap-2">
|
||||
<AlertTriangle className="h-4 w-4 dg-text-yellow" />污点 (Taints)
|
||||
<AlertTriangle className="h-4 w-4 dg-text-yellow" />{t('k8s.nodeDetail.taints')}
|
||||
</h2>
|
||||
{(!data.taints || data.taints.length === 0) ? (
|
||||
<p className="text-xs dg-text-muted py-4 text-center"> {i18n.t('kubernetes.node.noTaint')} </p>
|
||||
<p className="text-xs dg-text-muted py-4 text-center"> {t('kubernetes.node.noTaint')} </p>
|
||||
) : (
|
||||
<div className="space-y-2">
|
||||
{data.taints.map(( t: any, i: number) => (
|
||||
{data.taints.map(( tnt: any, i: number) => (
|
||||
<div key={i} className="flex items-center gap-2 text-xs">
|
||||
<Badge className={taintColor(t.effect)}>{t.effect}</Badge>
|
||||
<span className="text-[var(--dg-text-secondary)] font-mono">{t.key}</span>
|
||||
{t.value && <span className="dg-text-muted">= {t.value}</span>}
|
||||
<Badge className={taintColor(tnt.effect)}>{tnt.effect}</Badge>
|
||||
<span className="text-[var(--dg-text-secondary)] font-mono">{tnt.key}</span>
|
||||
{tnt.value && <span className="dg-text-muted">= {tnt.value}</span>}
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
@@ -308,7 +309,7 @@ export default function NodeDetailPage() {
|
||||
<Card className="dg-card">
|
||||
<CardContent className="p-4">
|
||||
<h2 className="text-sm font-semibold text-[var(--dg-text-primary)] mb-3 flex items-center gap-2">
|
||||
<Network className="h-4 w-4 dg-text-secondary" />标签 ({data.labels.length})
|
||||
<Network className="h-4 w-4 dg-text-secondary" />{t('k8s.nodeDetail.labels', { count: data.labels.length })}
|
||||
</h2>
|
||||
<div className="flex flex-wrap gap-1.5">
|
||||
{data.labels.map(( l: any, i: number) => (
|
||||
@@ -329,23 +330,23 @@ export default function NodeDetailPage() {
|
||||
<div className="px-4 py-3 border-b border-[var(--dg-border)]">
|
||||
<h2 className="text-sm font-semibold text-[var(--dg-text-primary)] flex items-center gap-2">
|
||||
<Container className="h-4 w-4 dg-text-cyan" />
|
||||
节点上的 Pod
|
||||
{t('k8s.nodeDetail.podsOnNode')}
|
||||
<Badge className="bg-[var(--dg-bg-active)]/50 text-[var(--dg-text-secondary)]">{data.pods?.length || 0}</Badge>
|
||||
</h2>
|
||||
</div>
|
||||
{(!data.pods || data.pods.length === 0) ? (
|
||||
<p className="text-xs dg-text-muted py-8 text-center"> {i18n.t('kubernetes.nodedetailpaget.s86d276f5')} </p>
|
||||
<p className="text-xs dg-text-muted py-8 text-center"> {t('k8s.nodeDetail.noPodsOnNode')} </p>
|
||||
) : (
|
||||
<Table>
|
||||
<TableHeader>
|
||||
<TableRow className="border-[var(--dg-border)] hover:bg-transparent">
|
||||
<TableHead className="dg-text-secondary"> {i18n.t('kubernetes.namespace.title')} </TableHead>
|
||||
<TableHead className="dg-text-secondary"> {i18n.t('kubernetes.secret.secretName')} </TableHead>
|
||||
<TableHead className="dg-text-secondary"> {i18n.t('system.terminalStatus')} </TableHead>
|
||||
<TableHead className="dg-text-secondary"> {t('kubernetes.namespace.title')} </TableHead>
|
||||
<TableHead className="dg-text-secondary"> {t('kubernetes.secret.secretName')} </TableHead>
|
||||
<TableHead className="dg-text-secondary"> {t('system.terminalStatus')} </TableHead>
|
||||
<TableHead className="dg-text-secondary">IP</TableHead>
|
||||
<TableHead className="dg-text-secondary">CPU 请求</TableHead>
|
||||
<TableHead className="dg-text-secondary"> {i18n.t('kubernetes.container.memoryRequest')} </TableHead>
|
||||
<TableHead className="dg-text-secondary"> {i18n.t('kubernetes.pod.restartCount')} </TableHead>
|
||||
<TableHead className="dg-text-secondary">{t('k8s.nodeDetail.cpuRequest')}</TableHead>
|
||||
<TableHead className="dg-text-secondary"> {t('kubernetes.container.memoryRequest')} </TableHead>
|
||||
<TableHead className="dg-text-secondary"> {t('kubernetes.pod.restartCount')} </TableHead>
|
||||
</TableRow>
|
||||
</TableHeader>
|
||||
<TableBody>
|
||||
|
||||
@@ -2771,7 +2771,19 @@
|
||||
"notFound": "Deployment not found",
|
||||
"podList": "Pod List",
|
||||
"logs": "Logs",
|
||||
"confirmDeleteHpa": "Confirm Delete HPA"
|
||||
"confirmDeleteHpa": "Confirm Delete HPA",
|
||||
"replicasSetTo": "Replicas set to {{count}}",
|
||||
"confirmRestart": "Confirm rolling restart of Deployment \"{{name}}\"?",
|
||||
"rollingUpdate": "{{action}} Rolling Update",
|
||||
"confirmRollingUpdate": "Confirm {{action}} rolling update of Deployment \"{{name}}\"?",
|
||||
"actionSuccess": "{{action}} Succeeded",
|
||||
"actionFailed": "{{action}} Failed",
|
||||
"rollingUpdated": "Deployment rolling update {{action}}d",
|
||||
"rollingUpdateImage": "Rolling updating to {{image}}",
|
||||
"deploymentDeleted": "{{name}} deleted",
|
||||
"confirmDeletePod": "Confirm delete Pod \"{{name}}\"? This action cannot be undone.",
|
||||
"deploymentNotFound": "Deployment not found: {{name}}",
|
||||
"imageLabel": "Image"
|
||||
},
|
||||
"podLogs": {
|
||||
"noLogs": "No logs",
|
||||
@@ -3234,6 +3246,29 @@
|
||||
"configured": "Configured (leave empty to keep)",
|
||||
"kubeconfigHint": "API Server address will be auto-parsed after pasting kubeconfig content",
|
||||
"cancel": "Cancel"
|
||||
},
|
||||
"nodeDetail": {
|
||||
"nodeTitle": "Node Details",
|
||||
"loadingNode": "Loading node details...",
|
||||
"loadFailed": "Failed to load node details",
|
||||
"systemInfo": "System Info",
|
||||
"resourceAllocation": "Resource Allocation",
|
||||
"cpuAllocated": "CPU Allocated",
|
||||
"cpuRealtimeUsage": "CPU Real-time Usage",
|
||||
"memAllocated": "Memory Allocated",
|
||||
"memRealtimeUsage": "Memory Real-time Usage",
|
||||
"podCount": "Pod Count",
|
||||
"cpuCapacityAlloc": "CPU Capacity / Allocatable",
|
||||
"memCapacityAlloc": "Memory Capacity / Allocatable",
|
||||
"podCapacityAlloc": "Pod Capacity / Allocatable",
|
||||
"coreUnit": "cores",
|
||||
"conditions": "Conditions",
|
||||
"noConditions": "No condition data",
|
||||
"taints": "Taints",
|
||||
"labels": "Labels ({{count}})",
|
||||
"podsOnNode": "Pods on Node",
|
||||
"noPodsOnNode": "No pods on this node",
|
||||
"cpuRequest": "CPU Request"
|
||||
}
|
||||
},
|
||||
"monitor": {
|
||||
|
||||
@@ -2771,7 +2771,19 @@
|
||||
"notFound": "未找到 Deployment",
|
||||
"podList": "Pod 列表",
|
||||
"logs": "日志",
|
||||
"confirmDeleteHpa": "确定删除 HPA"
|
||||
"confirmDeleteHpa": "确定删除 HPA",
|
||||
"replicasSetTo": "副本数已设置为 {{count}}",
|
||||
"confirmRestart": "确认滚动重启 Deployment \"{{name}}\"?",
|
||||
"rollingUpdate": "{{action}}滚动更新",
|
||||
"confirmRollingUpdate": "确认{{action}} Deployment \"{{name}}\" 的滚动更新?",
|
||||
"actionSuccess": "{{action}}成功",
|
||||
"actionFailed": "{{action}}失败",
|
||||
"rollingUpdated": "Deployment 滚动更新已{{action}}",
|
||||
"rollingUpdateImage": "正在滚动更新为 {{image}}",
|
||||
"deploymentDeleted": "{{name}} 已删除",
|
||||
"confirmDeletePod": "确认删除 Pod \"{{name}}\"?操作不可恢复。",
|
||||
"deploymentNotFound": "未找到 Deployment: {{name}}",
|
||||
"imageLabel": "镜像"
|
||||
},
|
||||
"podLogs": {
|
||||
"noLogs": "无日志",
|
||||
@@ -3234,6 +3246,29 @@
|
||||
"configured": "已配置(留空不修改)",
|
||||
"kubeconfigHint": "粘贴 kubeconfig 内容后将自动解析 API Server 地址",
|
||||
"cancel": "取消"
|
||||
},
|
||||
"nodeDetail": {
|
||||
"nodeTitle": "节点详情",
|
||||
"loadingNode": "加载节点详情...",
|
||||
"loadFailed": "无法加载节点详情",
|
||||
"systemInfo": "系统信息",
|
||||
"resourceAllocation": "资源分配率",
|
||||
"cpuAllocated": "CPU 已分配",
|
||||
"cpuRealtimeUsage": "CPU 实时使用",
|
||||
"memAllocated": "内存已分配",
|
||||
"memRealtimeUsage": "内存实时使用",
|
||||
"podCount": "Pod 数量",
|
||||
"cpuCapacityAlloc": "CPU 容量 / 可分配",
|
||||
"memCapacityAlloc": "内存容量 / 可分配",
|
||||
"podCapacityAlloc": "Pod 容量 / 可分配",
|
||||
"coreUnit": "核",
|
||||
"conditions": "节点条件",
|
||||
"noConditions": "无条件数据",
|
||||
"taints": "污点 (Taints)",
|
||||
"labels": "标签 ({{count}})",
|
||||
"podsOnNode": "节点上的 Pod",
|
||||
"noPodsOnNode": "该节点上暂无 Pod",
|
||||
"cpuRequest": "CPU 请求"
|
||||
}
|
||||
},
|
||||
"monitor": {
|
||||
|
||||
Reference in new issue
Block a user