diff options
Diffstat (limited to 'src/lib/ServiceList.tsx')
-rw-r--r-- | src/lib/ServiceList.tsx | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/lib/ServiceList.tsx b/src/lib/ServiceList.tsx index ae17a9c..8983bfa 100644 --- a/src/lib/ServiceList.tsx +++ b/src/lib/ServiceList.tsx @@ -6,6 +6,7 @@ import ListTable from '../components/ListTable'; import hooks from '../hooks/useAPIClient'; import ServiceContext from './ServiceContext'; import ServiceFilters from './ServiceFilters'; +import ServiceSearch from './ServiceSearch'; const ServiceList: React.FC = () => { const service = useContext(ServiceContext); @@ -26,11 +27,18 @@ const ServiceList: React.FC = () => { history.push(route); }; + const filters = ( + <> + {service.searchBy && <ServiceSearch />} + {service.filters && <ServiceFilters />} + </> + ); + return ( <Page title={service.name} actions={actions} - filters={<ServiceFilters />} + filters={filters} > <ListTable items={data} fields={service.tableFields} handleRowClick={handleRowClick} /> </Page> |