webpack/scenes/ContentViews/Details/Repositories/ContentViewRepositories.js in katello-4.5.1 vs webpack/scenes/ContentViews/Details/Repositories/ContentViewRepositories.js in katello-4.6.0.rc1
- old
+ new
@@ -89,11 +89,14 @@
const [statusSelected, setStatusSelected] = useState(ALL_STATUSES);
// repoTypes object format: [displayed_value]: API_value
const [repoTypes, setRepoTypes] = useState({});
const [bulkActionOpen, setBulkActionOpen] = useState(false);
const { repository_ids: repositoryIds = [] } = details;
-
+ const resetFilters = () => {
+ setTypeSelected(allRepositories);
+ setStatusSelected(ALL_STATUSES);
+ };
const {
isSelected,
selectOne,
selectNone,
selectedCount,
@@ -241,9 +244,10 @@
status,
activeFilters,
defaultFilters,
selectedCount,
selectNone,
+ resetFilters,
}}
ouiaId="content-view-repositories-table"
{...selectAll}
variant={TableVariant.compact}
autocompleteEndpoint="/repositories/auto_complete_search"