Skip to content

Commit

Permalink
Fix initial sort. Needs to happen on API call before transforming format
Browse files Browse the repository at this point in the history
  • Loading branch information
aloftus23 committed Jun 25, 2024
1 parent 7771e7f commit 369e9cd
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions frontend/src/pages/Scans/ScanTasksView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ export const ScanTasksView: React.FC = () => {
page,
pageSize: query.pageSize ?? PAGE_SIZE,
sort: sort[0]?.id ?? 'createdAt',
order: sort[0]?.desc ? 'DESC' : 'ASC',
order: 'DESC',
filters: tableFilters
}
}
Expand Down Expand Up @@ -391,11 +391,6 @@ export const ScanTasksView: React.FC = () => {
}))
});
}}
initialState={{
sorting: {
sortModel: [{ field: 'createdAt', sort: 'asc' }]
}
}}
pageSizeOptions={[15, 30, 50, 100]}
/>
)}
Expand Down

0 comments on commit 369e9cd

Please sign in to comment.