Skip to content

Commit

Permalink
Merge pull request #10579 from kdoberst/Bug-2014352-simple-fix-to-cou…
Browse files Browse the repository at this point in the history
…ld-not-filter-out-by-using-nade-name

Bug 2014352: Could not filter out machine by using node name on machines page (temp fix)
  • Loading branch information
openshift-merge-robot authored Dec 1, 2021
2 parents 158c23d + 3741664 commit ea0adcc
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion frontend/public/components/machine.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ import { useK8sWatchResource } from './utils/k8s-watch-hook';
import VirtualizedTable, { TableData } from './factory/Table/VirtualizedTable';
import { sortResourceByValue } from './factory/Table/sort';
import { useActiveColumns } from './factory/Table/active-columns-hook';
import { tableFilters } from './factory/table-filters';

const { common } = Kebab.factory;
const menuActions = [...Kebab.getExtensionsActionsForKind(MachineModel), ...common];
Expand Down Expand Up @@ -281,7 +282,10 @@ export const MachinePage: React.FC<MachinePageProps> = ({
namespace,
});

const [data, filteredData, onFilterChange] = useListPageFilter(machines);
// FIXME - there isn't a type for a simple filter like this nor is there an easy way to add this type
const machineFilter = [{ type: 'name', filter: tableFilters.machine }];
//@ts-ignore
const [data, filteredData, onFilterChange] = useListPageFilter(machines, machineFilter);

return (
<>
Expand Down

0 comments on commit ea0adcc

Please sign in to comment.