diff --git a/km-console/packages/layout-clusters-fe/src/pages/MutliClusterPage/List.tsx b/km-console/packages/layout-clusters-fe/src/pages/MutliClusterPage/List.tsx index a65ac3fd..d15cffcb 100644 --- a/km-console/packages/layout-clusters-fe/src/pages/MutliClusterPage/List.tsx +++ b/km-console/packages/layout-clusters-fe/src/pages/MutliClusterPage/List.tsx @@ -1,4 +1,5 @@ -import { AppContainer, Divider, Form, IconFont, Input, List, message, Modal, Progress, Spin, Tooltip, Utils } from 'knowdesign'; +import { AppContainer, Divider, Form, Input, List, message, Modal, Progress, Spin, Tooltip, Utils } from 'knowdesign'; +import { IconFont } from '@knowdesign/icons'; import moment from 'moment'; import API from '@src/api'; import React, { useEffect, useImperativeHandle, useMemo, useRef, useState } from 'react'; @@ -16,6 +17,10 @@ import { SearchParams } from './HomePage'; const DEFAULT_PAGE_SIZE = 10; +enum ClusterRunState { + Raft = 2, +} + const DeleteCluster = React.forwardRef((_, ref) => { const intl = useIntl(); const [form] = Form.useForm(); @@ -245,6 +250,7 @@ const ClusterList = (props: { searchParams: SearchParams; showAccessCluster: any metricPoints.push(line); }); + const runState = itemData.runState; const { Brokers: brokers, Zookeepers: zks, @@ -345,18 +351,21 @@ const ClusterList = (props: { searchParams: SearchParams; showAccessCluster: any
{brokers}
-
-
- - ZK + {/* 2: raft 模式 无zk */} + {runState !== ClusterRunState.Raft && ( +
+
+ + ZK +
+
{zookeepersAvailable === -1 ? '-' : zks}
-
{zookeepersAvailable === -1 ? '-' : zks}
-
+ )}
{metricPoints.map((row, index) => {