mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-2123] Process Pagination - There is no way to paginate the result (#2946)
* [ADF- 2123] Process Pagination - There is no way to paginate the result * Updated unimplemented pagination method. * * Refactored process-service component. * * Removed unused pagination methods from process-service component. * * Updated process/task list documentation with recent changes.
This commit is contained in:
committed by
Eugenio Romano
parent
f828e8e847
commit
1a41da514b
@@ -378,7 +378,16 @@ export class ProcessInstanceListComponent implements OnChanges, AfterContentInit
|
||||
}
|
||||
|
||||
updatePagination(params: PaginationQueryParams) {
|
||||
const needsReload = params.maxItems || params.skipCount;
|
||||
this.size = params.maxItems;
|
||||
this.page = this.currentPage(params.skipCount, params.maxItems);
|
||||
if (needsReload) {
|
||||
this.reload();
|
||||
}
|
||||
}
|
||||
|
||||
currentPage(skipCount: number, maxItems: number): number {
|
||||
return (skipCount && maxItems) ? Math.floor(skipCount / maxItems) : 0;
|
||||
}
|
||||
|
||||
get supportedPageSizes(): number[] {
|
||||
|
Reference in New Issue
Block a user