mirror of
https://github.com/didi/KnowStreaming.git
synced 2026-01-13 11:32:20 +08:00
fix: 健康状态详情优化 & Connector 样式优化 & 无MM2任务指标兜底页
This commit is contained in:
@@ -522,6 +522,7 @@ const ConnectorForm = (props: {
|
||||
const params = {
|
||||
...values,
|
||||
id: initFieldsValue?.id,
|
||||
jmxProperties: values.jmxProperties ? `{ "jmxProperties": "${values.jmxProperties}" }` : undefined,
|
||||
};
|
||||
Utils.put(api.batchConnectClusters, [params])
|
||||
.then((res) => {
|
||||
@@ -542,7 +543,7 @@ const ConnectorForm = (props: {
|
||||
setSelectedTabKey(undefined);
|
||||
try {
|
||||
const jmxPortInfo = JSON.parse(initFieldsValue.jmxProperties) || {};
|
||||
form.setFieldsValue({ ...initFieldsValue, jmxPort: jmxPortInfo.jmxPort });
|
||||
form.setFieldsValue({ ...initFieldsValue, jmxProperties: jmxPortInfo.jmxProperties });
|
||||
} catch {
|
||||
form.setFieldsValue({ ...initFieldsValue });
|
||||
}
|
||||
@@ -551,7 +552,7 @@ const ConnectorForm = (props: {
|
||||
useLayoutEffect(() => {
|
||||
try {
|
||||
const jmxPortInfo = JSON.parse(initFieldsValue.jmxProperties) || {};
|
||||
form.setFieldsValue({ ...initFieldsValue, jmxPort: jmxPortInfo.jmxPort });
|
||||
form.setFieldsValue({ ...initFieldsValue, jmxProperties: jmxPortInfo.jmxProperties });
|
||||
} catch {
|
||||
form.setFieldsValue({ ...initFieldsValue });
|
||||
}
|
||||
@@ -626,7 +627,7 @@ const ConnectorForm = (props: {
|
||||
))}
|
||||
</Select>
|
||||
</Form.Item>
|
||||
<Form.Item name="jmxPort" label="JMX Port" style={{ width: 202 }}>
|
||||
<Form.Item name="jmxProperties" label="JMX Port" style={{ width: 202 }}>
|
||||
<InputNumber min={0} max={99999} style={{ width: 202 }} />
|
||||
</Form.Item>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
import React, { useState } from 'react';
|
||||
import { message } from 'knowdesign';
|
||||
import { HeartTwoTone } from '@ant-design/icons';
|
||||
|
||||
const AccessClusterConfig = () => {
|
||||
const [count, setCount] = useState<number>(1);
|
||||
|
||||
const setErgeModal = () => {
|
||||
if (count >= 50) {
|
||||
message.success({
|
||||
content: 'Erge',
|
||||
icon: <HeartTwoTone />,
|
||||
});
|
||||
setCount(1);
|
||||
} else {
|
||||
setCount(count + 1);
|
||||
}
|
||||
};
|
||||
|
||||
return <div className="multi-cluster-erge" onClick={setErgeModal} />;
|
||||
};
|
||||
|
||||
export default AccessClusterConfig;
|
||||
@@ -6,6 +6,7 @@ import TourGuide, { MultiPageSteps } from '@src/components/TourGuide';
|
||||
import { healthSorceList, sliderValueMap, sortFieldList, sortTypes, statusFilters } from './config';
|
||||
import ClusterList from './List';
|
||||
import AccessClusters from './AccessCluster';
|
||||
import AccessCluster from './AccessClusterConfig';
|
||||
import CustomCheckGroup from './CustomCheckGroup';
|
||||
import { ClustersPermissionMap } from '../CommonConfig';
|
||||
import './index.less';
|
||||
@@ -359,6 +360,7 @@ const MultiClusterPage = () => {
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<AccessCluster />
|
||||
</div>
|
||||
</div>
|
||||
<div className="multi-cluster-page-dashboard">
|
||||
|
||||
@@ -343,6 +343,14 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
.multi-cluster-erge {
|
||||
position: absolute;
|
||||
width: 15px;
|
||||
height: 15px;
|
||||
top: 100px;
|
||||
left: 20px;
|
||||
background-color: transparent;
|
||||
}
|
||||
}
|
||||
&-dashboard {
|
||||
& > .dcloud-spin-nested-loading > .dcloud-spin-container::after {
|
||||
|
||||
Reference in New Issue
Block a user