Skip to content

Commit

Permalink
Fixed todos
Browse files Browse the repository at this point in the history
  • Loading branch information
richard-cox committed Jan 9, 2018
1 parent c3d5c43 commit 5dc32d2
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
3 changes: 1 addition & 2 deletions src/app/shared/components/list/list.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,7 @@ export class ListComponent<T> implements OnInit, OnDestroy, AfterViewInit {

this.paginationController = new ListPaginationController(this._store, this.dataSource);

// TODO: This should be configurable per list
this.paginator.pageSizeOptions = [5, 10, 20];
this.paginator.pageSizeOptions = this.listConfigService.pageSizeOptions;
const paginationStoreToWidget = this.paginationController.pagination$.do((pagination: ListPagination) => {
this.paginator.length = pagination.totalResults;
this.paginator.pageIndex = pagination.pageIndex - 1;
Expand Down
3 changes: 1 addition & 2 deletions src/app/shared/data-sources/list-data-source.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ export abstract class ListDataSource<T, A = T> extends DataSource<T> implements
public page$: Observable<T[]>;

// Store related
public entityKey: string; // TODO: RC Needed?
public entityKey: string;

// Add item
public addItem: T;
Expand Down Expand Up @@ -85,7 +85,6 @@ export abstract class ListDataSource<T, A = T> extends DataSource<T> implements
action: this.action,
schema: [this.sourceScheme]
},
null,
isLocal
);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ export function getPaginationKey(action: PaginatedAction) {

export const getPaginationObservables = <T = any>(
{ store, action, schema }: { store: Store<AppState>, action: PaginatedAction, schema: Schema },
uid?: string, // TODO: Delete me?
isLocal = false
): PaginationObservables<T> => {
const { entityKey, paginationKey } = action;
Expand Down

0 comments on commit 5dc32d2

Please sign in to comment.