Skip to content

Commit

Permalink
apply to org search page
Browse files Browse the repository at this point in the history
  • Loading branch information
rrchai committed Jan 17, 2024
1 parent 72b8061 commit 359d2ce
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,6 @@ export class ChallengeSearchComponent
// update challenges and total number of results
this.searchResultsCount = page.totalElements;
this.challenges = page.challenges;
console.log(this.paginator.pageNumber);
});
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ export class OrgSearchComponent implements OnInit, AfterContentInit, OnDestroy {
defaultSortedBy: OrganizationSort = 'challenge_count';
defaultPageNumber = 0;
defaultPageSize = 24;
@ViewChild('paginator', { static: true }) paginator!: PaginatorComponent;
@ViewChild('paginator', { static: false }) paginator!: PaginatorComponent;

// define filters
sortFilters: Filter[] = organizationSortFilter;
Expand Down Expand Up @@ -163,7 +163,7 @@ export class OrgSearchComponent implements OnInit, AfterContentInit, OnDestroy {
this.selectedCategories = this.splitParam(params['categories']);
this.searchedTerms = params['searchTerms'];
this.selectedPageNumber = +params['pageNumber'] || this.defaultPageNumber;
this.selectedPageSize = +params['pageSize'] || this.defaultPageSize;
this.selectedPageSize = this.defaultPageSize; // no available pageSize options for users
this.sortedBy = params['sort'] || this.defaultSortedBy;

const defaultQuery: OrganizationSearchQuery = {
Expand Down

0 comments on commit 359d2ce

Please sign in to comment.