Skip to content

Commit

Permalink
Fixed a bug in the Pager component introduced with the upgrade to Pri…
Browse files Browse the repository at this point in the history
…meVue 4 where the default page was 0 rather than 1.
  • Loading branch information
rizen committed Oct 24, 2024
1 parent 5d9d218 commit 2572399
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
12 changes: 7 additions & 5 deletions app/components/ving/Pager.vue
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
<template>
<Paginator :template="{
'640px': 'PrevPageLink CurrentPageReport NextPageLink',
'960px': 'FirstPageLink PrevPageLink CurrentPageReport NextPageLink LastPageLink',
'1300px': 'FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink',
default: 'FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink JumpToPageDropdown'
}" :rowsPerPageOptions="[10, 20, 50, 100]" :alwaysShow="false" :totalRecords="kind.paging.totalItems"
'640px': 'PrevPageLink CurrentPageReport NextPageLink',
'960px': 'FirstPageLink PrevPageLink CurrentPageReport NextPageLink LastPageLink',
'1300px': 'FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink',
default: 'FirstPageLink PrevPageLink PageLinks NextPageLink LastPageLink JumpToPageDropdown'
}"
:first="1"
:rowsPerPageOptions="[10, 20, 50, 100]" :alwaysShow="false" :totalRecords="kind.paging.totalItems"
:rows="kind.paging.itemsPerPage" :pageCount="kind.paging.totalPages" :page="kind.paging.page" @page="changePage">
</Paginator>
</template>
Expand Down
3 changes: 2 additions & 1 deletion ving/docs/change-log.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ outline: deep
* Updated the redis client to trap bad connection strings with an error message.
* Updated the drizzle client to use dotenv to get the connection string.
* Updated the drizzle client to trap bad connection strings with an error message.
* Fix potential bug where someone enters a negative page number into the paginator.
* Fixed a potential bug where someone enters a negative page number into the paginator.
* Fixed a bug in the Pager component introduced with the upgrade to PrimeVue 4 where the default page was 0 rather than 1.

### 2024-10-01
* Added colin's patch for mysql pagination.
Expand Down

0 comments on commit 2572399

Please sign in to comment.