diff options
author | sowgro <tpoke.ferrari@gmail.com> | 2025-04-01 20:04:33 -0400 |
---|---|---|
committer | sowgro <tpoke.ferrari@gmail.com> | 2025-04-01 20:04:33 -0400 |
commit | 92fbcbfd6ade1c5fe0cc3c37d6a6914ef1d2a2a4 (patch) | |
tree | e2f61b473073931ce2dc78ea6f967da2ae1589b0 /ufund-ui/src/app/components/need-list/need-list.component.ts | |
parent | 734d3d380cd70e87474adebedec5e230959bcf81 (diff) | |
download | JellySolutions-92fbcbfd6ade1c5fe0cc3c37d6a6914ef1d2a2a4.tar.gz JellySolutions-92fbcbfd6ade1c5fe0cc3c37d6a6914ef1d2a2a4.tar.bz2 JellySolutions-92fbcbfd6ade1c5fe0cc3c37d6a6914ef1d2a2a4.zip |
Add skip to first / last page in pagination
Diffstat (limited to 'ufund-ui/src/app/components/need-list/need-list.component.ts')
-rw-r--r-- | ufund-ui/src/app/components/need-list/need-list.component.ts | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/ufund-ui/src/app/components/need-list/need-list.component.ts b/ufund-ui/src/app/components/need-list/need-list.component.ts index cd3d9bd..06a612e 100644 --- a/ufund-ui/src/app/components/need-list/need-list.component.ts +++ b/ufund-ui/src/app/components/need-list/need-list.component.ts @@ -74,12 +74,22 @@ export class NeedListComponent { decrementPage() { this.currentPage--; - this.updateVisibleNeeds(); + this.updateVisibleNeeds(); } incrementPage() { this.currentPage++; - this.updateVisibleNeeds(); + this.updateVisibleNeeds(); + } + + lastPage() { + this.currentPage = this.totalPages - 1 + this.updateVisibleNeeds() + } + + firstPage() { + this.currentPage = 0 + this.updateVisibleNeeds() } editNeedsPerPage(amount: number) { @@ -135,7 +145,7 @@ export class NeedListComponent { ngOnInit(): void { this.refresh() - + } changeSortMode(form : any) { @@ -269,7 +279,4 @@ export class NeedListComponent { } } } -function not(location: string) { - throw new Error('Function not implemented.'); -} |