Skip to content

Commit 2adf20f

Browse files
committed
Remove location type filter from Location.jobs tab
1 parent b32f98e commit 2adf20f

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

src/components/job/JobRaListFilters.tsx

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,19 @@ import { TextInput } from "react-admin";
66
import JobTypeRaFilter from "./JobRaTypeFilter";
77
import { LocationRaTypeFilter } from "../location";
88

9-
const JobRaListFilters = () => {
9+
const JobRaListFilters = ({
10+
withLocationType = true,
11+
}: {
12+
withLocationType?: boolean;
13+
}) => {
1014
return (
1115
<FilterLiveForm>
1216
<Box display="flex" alignItems="flex-end">
13-
<Box component="span" mr={2} sx={{ flex: "0.2" }}>
14-
<LocationRaTypeFilter />
15-
</Box>
17+
{withLocationType && (
18+
<Box component="span" mr={2} sx={{ flex: "0.2" }}>
19+
<LocationRaTypeFilter />
20+
</Box>
21+
)}
1622

1723
<Box component="span" mr={2} sx={{ flex: "0.2" }}>
1824
<JobTypeRaFilter />

src/components/job/JobRaListForLocation.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const JobRaListForLocation = ({
1515
resource="jobs"
1616
actions={
1717
<ListActions>
18-
<JobRaListFilters />
18+
<JobRaListFilters withLocationType={false} />
1919
</ListActions>
2020
}
2121
filter={{ location_id: locationId }}

0 commit comments

Comments
 (0)