Skip to content

Commit

Permalink
frontend: Get a high number of packages until we add real pagination
Browse files Browse the repository at this point in the history
Due to how the backend changed how the items can get fetched (making
the pagination mandatory), the list of packages gotten by default was
just 10.

We should fix this by applying a real pagination in the packages'
list, but until then, this patch requests a high number of packages
so the UX is a bit better until we fix the pagination in the UI.
  • Loading branch information
joaquimrocha committed Jun 2, 2022
1 parent e4f2e06 commit ab5438b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion frontend/src/components/Packages/List.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ function List(props: { appID: string }) {
React.useEffect(() => {
applicationsStore().addChangeListener(onChange);
if (!packages) {
API.getPackages(props.appID)
// @todo: Request the pagination according to the page configuration in the table below.
API.getPackages(props.appID, '', { perpage: 1000 })
.then(result => {
if (_.isNull(result.packages)) {
setPackages([]);
Expand Down

0 comments on commit ab5438b

Please sign in to comment.