modify alert bug

This commit is contained in:
silenceqi 2021-09-07 10:03:40 +08:00
parent 13ce75d197
commit e01c081ed1
3 changed files with 6 additions and 5 deletions

View File

@ -68,7 +68,7 @@ export const RequestStatusBar: FunctionComponent<Props> = ({
let content: React.ReactNode = null;
const clusterContent = (<EuiFlexItem grow={false} style={{marginRight:'auto'}}>
<EuiBadge>
{selectedCluster.endpoint}&nbsp;-&nbsp;{selectedCluster.version}
{selectedCluster.host}&nbsp;-&nbsp;{selectedCluster.version}
</EuiBadge>
</EuiFlexItem>);

View File

@ -58,6 +58,7 @@ export default {
name: item.name,
id: item.id,
endpoint: item.endpoint,
host: item.host,
version: item.version,
};
})
@ -131,10 +132,10 @@ export default {
if(pathname && global.selectedClusterID){
const newPart = `/elasticsearch/${global.selectedClusterID}/`;
if(!pathname.includes('elasticsearch')){
history.replace(pathname+newPart+search)
history.replace(pathname+newPart+ (search || ''))
}else{
const newPath = pathname.replace(/\/elasticsearch\/(\w+)\/?/, newPart);
history.replace(newPath+search)
history.replace(newPath+(search || ''))
}
}
},

View File

@ -93,8 +93,8 @@ class Index extends React.Component {
}
},{
title: '集群地址',
dataIndex: 'endpoint',
key: 'endpoint',
dataIndex: 'host',
key: 'host',
},
{
title: '监控启用状态',