webpack/scenes/RedHatRepositories/components/SearchBar.js in katello-3.8.1 vs webpack/scenes/RedHatRepositories/components/SearchBar.js in katello-3.9.0.rc1
- old
+ new
@@ -28,11 +28,11 @@
super(props);
this.state = {
query: '',
searchList: 'available',
- filters: [],
+ filters: ['rpm'],
};
this.onSearch = this.onSearch.bind(this);
this.onSelectSearchList = this.onSelectSearchList.bind(this);
}
@@ -79,11 +79,11 @@
if (enabledSearch !== null) {
const enabledParams = {
perPage: this.props.enabledRepositories.pagination.perPage,
search: enabledSearch,
};
- this.props.loadEnabledRepos(enabledParams, enabledSearch);
+ this.props.loadEnabledRepos(enabledParams);
}
}
render() {
const { repoParams } = this.props;
@@ -95,10 +95,11 @@
</FormGroup>
<MultiSelect
value={this.state.filters}
options={filterOptions}
- noneSelectedText={__("Filter by type")}
+ defaultValues={['rpm']}
+ noneSelectedText={__('Filter by type')}
onChange={(e) => {
const values = [...e.target.options]
.filter(({ selected }) => selected)
.map(({ value }) => value);
this.onSelectFilterType(values);