]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/commitdiff
Fix missing pagination when listing channel syncs
authorChocobozzz <me@florianbigard.com>
Wed, 14 Sep 2022 13:18:05 +0000 (15:18 +0200)
committerChocobozzz <me@florianbigard.com>
Wed, 14 Sep 2022 13:18:05 +0000 (15:18 +0200)
client/src/app/+my-library/my-video-channel-syncs/my-video-channel-syncs.component.html
client/src/app/+my-library/my-video-channel-syncs/my-video-channel-syncs.component.ts

index c2fed8112f6e79d0afc26c6eddc9d992e834972b..5f368d4304d7840af8037e53611a53e40bf81a9f 100644 (file)
@@ -12,7 +12,7 @@
 <p-table
   *ngIf="syncEnabled()" [value]="channelSyncs" [lazy]="true"
   [paginator]="totalRecords > 0" [totalRecords]="totalRecords" [rows]="rowsPerPage" [rowsPerPageOptions]="rowsPerPageOptions"
-  [sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)" dataKey="id"
+  [first]="pagination.start" [sortField]="sort.field" [sortOrder]="sort.order" (onLazyLoad)="loadLazy($event)" dataKey="id"
   [showCurrentPageReport]="true" i18n-currentPageReportTemplate
   currentPageReportTemplate="Showing {{'{first}'}} to {{'{last}'}} of {{'{totalRecords}'}} synchronizations"
   [expandedRowKeys]="expandedRows"
index 0c429e5dd1fecf45f22bf8ff7d5559d630650240..2908474182374db59486344c03283d5faf4a76fc 100644 (file)
@@ -75,6 +75,7 @@ export class MyVideoChannelSyncsComponent extends RestTable implements OnInit {
       .subscribe({
         next: res => {
           this.channelSyncs = res.data
+          this.totalRecords = res.total
         },
         error: err => {
           this.error = err.message