Skip to content

Commit

Permalink
Add filter and sort to parkeren list page
Browse files Browse the repository at this point in the history
  • Loading branch information
OscarBakker committed Dec 16, 2024
1 parent 6abdd15 commit e3ede67
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion src/client/pages/Parkeren/ParkerenList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ export function ParkerenList() {

return (
<ListPagePaginated
items={parkeerVergunningenFromThemaVergunningen}
items={parkeerVergunningenFromThemaVergunningen
.filter(tableConfig[params.kind].filter)
.sort(tableConfig[params.kind].sort)}
backLinkTitle={ThemaTitles.PARKEREN}
title={title ?? ''}
appRoute={AppRoutes['PARKEREN/LIST']}
Expand Down
4 changes: 2 additions & 2 deletions src/client/pages/Parkeren/useParkerenData.hook.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const PARKEER_CASE_TYPES: Set<DecosCaseType> = new Set([
CaseType.TouringcarJaarontheffing,
]);

function getVergunningenFromThemaVergunningen(
function getParkeervergunningen(
content: VergunningFrontendV2[] | Vergunning[] | null
) {
return addLinkElementToProperty<VergunningFrontendV2 | Vergunning>(
Expand Down Expand Up @@ -47,7 +47,7 @@ export function useParkerenData() {
: VERGUNNINGENv2.content) ?? [];

const parkeerVergunningenFromThemaVergunningen =
getVergunningenFromThemaVergunningen(vergunningen);
getParkeervergunningen(vergunningen);
const hasMijnParkerenVergunningen = !!PARKEREN.content?.isKnown;

return {
Expand Down

0 comments on commit e3ede67

Please sign in to comment.