41914: implemented pagination sort direction/field

This commit is contained in:
Lotte Hofstede
2017-06-15 13:32:15 +02:00
parent c63bd7c2ef
commit 6db165b7a3
9 changed files with 342 additions and 211 deletions

View File

@@ -1,7 +1,10 @@
<ds-pagination [paginationOptions]="config"
[collectionSize]="(pageInfo | async)?.totalElements"
[sortOptions]="sortConfig"
(pageChange)="onPageChange($event)"
(pageSizeChange)="onPageSizeChange($event)">
(pageSizeChange)="onPageSizeChange($event)"
(sortDirectionChange)="onSortDirectionChange($event)"
(sortFieldChange)="onSortDirectionChange($event)">
<ul *ngIf="objects.hasSucceeded | async">
<li *ngFor="let object of (objects.payload | async) | paginate: { itemsPerPage: (pageInfo | async)?.elementsPerPage, currentPage: (pageInfo | async)?.currentPage, totalItems: (pageInfo | async)?.totalElements }">
<ds-object-list-element [object]="object"></ds-object-list-element>