Skip to content

Commit

Permalink
fix: lose Monitored in cluster editing (#123)
Browse files Browse the repository at this point in the history
Co-authored-by: yaojiping <[email protected]>
  • Loading branch information
yaojp123 and yaojiping authored Feb 13, 2025
1 parent 304fad0 commit 2f94f14
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions web/src/pages/System/Cluster/Form.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,17 +68,7 @@ class ClusterForm extends React.Component {
];

componentDidMount() {
//console.log(this.props.clusterConfig.editMode)
const { match, dispatch, clusterConfig } = this.props;
if (clusterConfig?.editValue) {

this.setState({
monitored: clusterConfig?.editValue.hasOwnProperty("monitored")
? clusterConfig?.editValue?.monitored
: false,
});
}

dispatch({
type: "clusterConfig/fetchCluster",
payload: {
Expand Down Expand Up @@ -107,7 +97,8 @@ class ClusterForm extends React.Component {
this.setState({
needAuth,
isManual,
collectMode
collectMode,
monitored: editValue?.hasOwnProperty("monitored") ? editValue?.monitored : false,
});
}
});
Expand Down

0 comments on commit 2f94f14

Please sign in to comment.