mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
[ML] File data viz fix index pattern warning after index change (#57807)
This commit is contained in:
parent
c31c7ee4c7
commit
3c51fb0314
1 changed files with 9 additions and 1 deletions
|
@ -325,9 +325,17 @@ export class ImportView extends Component {
|
|||
|
||||
onIndexChange = e => {
|
||||
const name = e.target.value;
|
||||
const { indexNames, indexPattern, indexPatternNames } = this.state;
|
||||
|
||||
this.setState({
|
||||
index: name,
|
||||
indexNameError: isIndexNameValid(name, this.state.indexNames),
|
||||
indexNameError: isIndexNameValid(name, indexNames),
|
||||
// if index pattern has been altered, check that it still matches the inputted index
|
||||
...(indexPattern === ''
|
||||
? {}
|
||||
: {
|
||||
indexPatternNameError: isIndexPatternNameValid(indexPattern, indexPatternNames, name),
|
||||
}),
|
||||
});
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue