[ADF-2444] supportedPageSize is used only via input parameter (#3087)

* [ADF-2444] supportedPageSize is used only via input parameter

* [ADF-2444] removed white space

* [ADF-2444] added deprecation to supportedPageSize attribute of paginated interface
This commit is contained in:
Vito
2018-03-20 17:23:10 +00:00
committed by Eugenio Romano
parent 436a911e0d
commit ebec5ea8d7
3 changed files with 10 additions and 3 deletions

View File

@@ -22,6 +22,10 @@ import { PaginationQueryParams } from './pagination-query-params.interface';
export interface PaginatedComponent {
pagination: BehaviorSubject<Pagination>;
/**
* @deprecated : the supported page size should be retrieved via the user preferences
* and given to the pagination component, and not retrieved by the paginated object
*/
supportedPageSizes: number[];
updatePagination(params: PaginationQueryParams);
}

View File

@@ -95,7 +95,6 @@ export class PaginationComponent implements OnInit, OnDestroy {
ngOnInit() {
if (this.target) {
this.supportedPageSizes = this.target.supportedPageSizes;
this.paginationSubscription = this.target.pagination.subscribe(page => {
this.pagination = page;
this.cdr.detectChanges();