From 9e5505c2978591d4c6628f2a0b274d05570d12e0 Mon Sep 17 00:00:00 2001 From: argirok Date: Mon, 16 Oct 2023 12:13:42 +0300 Subject: [PATCH] fix issue with enermaps tab: use search-results instead of search-tab --- src/app/community/community.component.html | 20 +++++++++++++------- src/app/community/community.component.ts | 3 ++- 2 files changed, 15 insertions(+), 8 deletions(-) diff --git a/src/app/community/community.component.html b/src/app/community/community.component.html index 5a60ce9..46f3a18 100644 --- a/src/app/community/community.component.html +++ b/src/app/community/community.component.html @@ -737,9 +737,11 @@ *ngIf="activeTab == 'enermaps' && communityId == 'enermaps' && fetchFeaturedDatasets.searchUtils.totalResults > 0 && isEntityEnabled('dataset')">
- +
+
+ Featured Datasets +
+
Here are listed some of the most important energy datasets as selected by energy experts.
@@ -747,12 +749,16 @@ using only well-known datasets which you can trust.
- + [page]="fetchFeaturedDatasets.searchUtils.page" [pageSize]="size" + [totalResults]="fetchFeaturedDatasets.searchUtils.totalResults" > -
+ +
diff --git a/src/app/community/community.component.ts b/src/app/community/community.component.ts index 8cba6db..6db3098 100644 --- a/src/app/community/community.component.ts +++ b/src/app/community/community.component.ts @@ -386,7 +386,6 @@ export class CommunityComponent { ) ) { this.fetchFeaturedDatasets.getAllResultsForCommunity("dataset", this.communityId, page, size, this.properties, "enermaps::selection"); - // console.log(this.fetchFeaturedDatasets); } this.reloadFeaturedDatasets = false; } @@ -663,5 +662,7 @@ export class CommunityComponent { public updatePage(event) { this.page = event.value; + this.fetchFeaturedDatasets.searchUtils.page = event.value; + this.fetchFeaturedDatasets.results = this.fetchFeaturedDatasets.allResults.slice((this.page - 1) * this.searchNumber, this.page * this.searchNumber) ; } }