enable impact factors for inspired-ris, show all featured datasets in enermaps featured tab

This commit is contained in:
argirok 2021-09-07 13:13:06 +03:00
parent 973ebda18e
commit d34fcacf1c
2 changed files with 64 additions and 62 deletions

View File

@ -368,7 +368,8 @@
resultType: 'publication', fetch: fetchPublications, resultType: 'publication', fetch: fetchPublications,
searchLinkToAdvancedPage: properties.searchLinkToAdvancedResults, searchLinkToAdvancedPage: properties.searchLinkToAdvancedResults,
params: getParamsForSearchLink('publications'), params: getParamsForSearchLink('publications'),
type: 'publication', typeName: 'publication', showImpactFactors:(community.communityId == 'elixir-gr')}"> type: 'publication', typeName: 'publication',
showImpactFactors:(community.communityId == 'elixir-gr' || community.communityId == 'inspired-ris' )}">
</ng-container> </ng-container>
</ng-template> </ng-template>
<ng-template #datasets_tab> <ng-template #datasets_tab>
@ -376,7 +377,8 @@
resultType: 'dataset', fetch: fetchDatasets, resultType: 'dataset', fetch: fetchDatasets,
searchLinkToAdvancedPage: properties.searchLinkToAdvancedResults, searchLinkToAdvancedPage: properties.searchLinkToAdvancedResults,
params: getParamsForSearchLink('datasets'), params: getParamsForSearchLink('datasets'),
type: 'dataset', typeName: 'research data', showImpactFactors:(community.communityId == 'elixir-gr')}"> type: 'dataset', typeName: 'research data',
showImpactFactors:(community.communityId == 'elixir-gr' || community.communityId == 'inspired-ris')}">
</ng-container> </ng-container>
</ng-template> </ng-template>
<ng-template #software_tab> <ng-template #software_tab>
@ -384,7 +386,8 @@
resultType: 'software', fetch: fetchSoftware, resultType: 'software', fetch: fetchSoftware,
searchLinkToAdvancedPage: properties.searchLinkToAdvancedResults, searchLinkToAdvancedPage: properties.searchLinkToAdvancedResults,
params: getParamsForSearchLink('software'), params: getParamsForSearchLink('software'),
type: 'software', typeName: 'software', showImpactFactors:(community.communityId == 'elixir-gr')}"> type: 'software', typeName: 'software',
showImpactFactors:(community.communityId == 'elixir-gr' || community.communityId == 'inspired-ris')}">
</ng-container> </ng-container>
</ng-template> </ng-template>
<ng-template #other_tab> <ng-template #other_tab>
@ -392,7 +395,8 @@
resultType: 'other', fetch: fetchOrps, resultType: 'other', fetch: fetchOrps,
searchLinkToAdvancedPage: properties.searchLinkToAdvancedResults, searchLinkToAdvancedPage: properties.searchLinkToAdvancedResults,
params: getParamsForSearchLink('other'), params: getParamsForSearchLink('other'),
type: 'orp', typeName: 'other products', showImpactFactors:(community.communityId == 'elixir-gr')}"> type: 'orp', typeName: 'other products',
showImpactFactors:(community.communityId == 'elixir-gr' || community.communityId == 'inspired-ris')}">
</ng-container> </ng-container>
</ng-template> </ng-template>
<ng-template #analytics_tab> <ng-template #analytics_tab>

View File

@ -14,14 +14,12 @@ import {StatisticsForDashboardComponent} from '../statistics/statistics.componen
import {StringUtils} from '../openaireLibrary/utils/string-utils.class'; import {StringUtils} from '../openaireLibrary/utils/string-utils.class';
import {PiwikHelper} from '../utils/piwikHelper'; import {PiwikHelper} from '../utils/piwikHelper';
import {HelperFunctions} from "../openaireLibrary/utils/HelperFunctions.class";
import {SearchCommunityDataprovidersService} from "../openaireLibrary/connect/contentProviders/searchDataproviders.service"; import {SearchCommunityDataprovidersService} from "../openaireLibrary/connect/contentProviders/searchDataproviders.service";
import {SearchCommunityProjectsService} from "../openaireLibrary/connect/projects/searchProjects.service"; import {SearchCommunityProjectsService} from "../openaireLibrary/connect/projects/searchProjects.service";
import {SearchResearchResultsService} from "../openaireLibrary/services/searchResearchResults.service"; import {SearchResearchResultsService} from "../openaireLibrary/services/searchResearchResults.service";
import {RouterHelper} from "../openaireLibrary/utils/routerHelper.class"; import {RouterHelper} from "../openaireLibrary/utils/routerHelper.class";
import {SEOService} from "../openaireLibrary/sharedComponents/SEO/SEO.service"; import {SEOService} from "../openaireLibrary/sharedComponents/SEO/SEO.service";
import {UserManagementService} from "../openaireLibrary/services/user-management.service"; import {UserManagementService} from "../openaireLibrary/services/user-management.service";
import {SubscribeComponent} from "../utils/subscribe/subscribe.component";
import {SearchCustomFilter} from "../openaireLibrary/searchPages/searchUtils/searchUtils.class"; import {SearchCustomFilter} from "../openaireLibrary/searchPages/searchUtils/searchUtils.class";
import {FetchResearchResults} from "../openaireLibrary/utils/fetchEntitiesClasses/fetchResearchResults.class"; import {FetchResearchResults} from "../openaireLibrary/utils/fetchEntitiesClasses/fetchResearchResults.class";
import {ErrorCodes} from "../openaireLibrary/utils/properties/errorCodes"; import {ErrorCodes} from "../openaireLibrary/utils/properties/errorCodes";
@ -37,16 +35,16 @@ import {Filter} from "../openaireLibrary/searchPages/searchUtils/searchHelperCla
export class CommunityComponent { export class CommunityComponent {
public url: string = null; public url: string = null;
public projectTotal = null; public projectTotal = null;
public contentProviderTotal = null; public contentProviderTotal = null;
public projectsCalculated: boolean = false; public projectsCalculated: boolean = false;
public contentProvidersCalculated: boolean = false; public contentProvidersCalculated: boolean = false;
params: any = {}; params: any = {};
properties: EnvProperties = properties; properties: EnvProperties = properties;
public errorCodes: ErrorCodes = new ErrorCodes(); public errorCodes: ErrorCodes = new ErrorCodes();
// Request results of each tab only the one time (first time tab is clicked) // Request results of each tab only the one time (first time tab is clicked)
private reloadPublications: boolean = true; private reloadPublications: boolean = true;
@ -54,7 +52,7 @@ export class CommunityComponent {
private reloadSoftware: boolean = true; private reloadSoftware: boolean = true;
private reloadOrps: boolean = true; private reloadOrps: boolean = true;
private reloadFeaturedDatasets: boolean = true; private reloadFeaturedDatasets: boolean = true;
// Variables for publications, research data, projects, content providers, related content providers tabs // Variables for publications, research data, projects, content providers, related content providers tabs
public fetchPublications: FetchResearchResults; public fetchPublications: FetchResearchResults;
public fetchDatasets: FetchResearchResults; public fetchDatasets: FetchResearchResults;
@ -62,31 +60,31 @@ export class CommunityComponent {
public fetchOrps: FetchResearchResults; public fetchOrps: FetchResearchResults;
public fetchFeaturedDatasets: FetchResearchResults; public fetchFeaturedDatasets: FetchResearchResults;
public searchNumber: number = 5; public searchNumber: number = 5;
@Input() communityId = null; @Input() communityId = null;
public community = null; public community = null;
public communityInfo = null; public communityInfo = null;
public showLoading: boolean = true; public showLoading: boolean = true;
masterZenodoCommunity = null; masterZenodoCommunity = null;
zenodoCommunityIdS = []; zenodoCommunityIdS = [];
showAllDescription = false; showAllDescription = false;
public thresholdDescription: number = 500; public thresholdDescription: number = 500;
public descriptionDiff: number = 100; public descriptionDiff: number = 100;
subscribers: number = 0; subscribers: number = 0;
subs: Subscription[] = []; subs: Subscription[] = [];
@ViewChild(StatisticsForDashboardComponent) statistics: StatisticsForDashboardComponent = null; @ViewChild(StatisticsForDashboardComponent) statistics: StatisticsForDashboardComponent = null;
public activeTab = "summary"; public activeTab = "summary";
public show: string = 'overview'; public show: string = 'overview';
public analyticsActiveTab: string = ""; public analyticsActiveTab: string = "";
public analyticsChecked: boolean = false; public analyticsChecked: boolean = false;
searchLinkToResults: string = null; searchLinkToResults: string = null;
searchLinkToProjects: string = null; searchLinkToProjects: string = null;
searchLinkToDataProviders: string = null; searchLinkToDataProviders: string = null;
searchLinkToAdvancedResults: string = null; searchLinkToAdvancedResults: string = null;
@ -123,14 +121,14 @@ export class CommunityComponent {
private _zenodoCommunitieService: ZenodoCommunitiesService, private _zenodoCommunitieService: ZenodoCommunitiesService,
private seoService: SEOService, private seoService: SEOService,
private userManagementService: UserManagementService) { private userManagementService: UserManagementService) {
var description = "OpenAIRE - Connect, Community Dashboard, research community"; var description = "OpenAIRE - Connect, Community Dashboard, research community";
var title = "OpenAIRE - Connect"; var title = "OpenAIRE - Connect";
this._meta.updateTag({content: description}, "name='description'"); this._meta.updateTag({content: description}, "name='description'");
this._meta.updateTag({content: description}, "property='og:description'"); this._meta.updateTag({content: description}, "property='og:description'");
this._meta.updateTag({content: title}, "property='og:title'"); this._meta.updateTag({content: title}, "property='og:title'");
this._title.setTitle(title); this._title.setTitle(title);
this.fetchPublications = new FetchResearchResults(this._searchResearchResultsService); this.fetchPublications = new FetchResearchResults(this._searchResearchResultsService);
this.fetchDatasets = new FetchResearchResults(this._searchResearchResultsService); this.fetchDatasets = new FetchResearchResults(this._searchResearchResultsService);
this.fetchSoftware = new FetchResearchResults(this._searchResearchResultsService); this.fetchSoftware = new FetchResearchResults(this._searchResearchResultsService);
@ -138,7 +136,7 @@ export class CommunityComponent {
this.fetchFeaturedDatasets = new FetchResearchResults(this._searchResearchResultsService); this.fetchFeaturedDatasets = new FetchResearchResults(this._searchResearchResultsService);
} }
public ngOnInit() { public ngOnInit() {
this.searchLinkToResults = this.properties.searchLinkToResults; this.searchLinkToResults = this.properties.searchLinkToResults;
this.searchLinkToProjects = this.properties.searchLinkToProjects; this.searchLinkToProjects = this.properties.searchLinkToProjects;
@ -159,7 +157,7 @@ export class CommunityComponent {
if (community.description != null && (community.description.length - this.thresholdDescription <= this.descriptionDiff)) { if (community.description != null && (community.description.length - this.thresholdDescription <= this.descriptionDiff)) {
this.thresholdDescription = community.description.length; this.thresholdDescription = community.description.length;
} }
if (this.properties.environment == "development") { if (this.properties.environment == "development") {
this.params = {communityId: community.communityId}; this.params = {communityId: community.communityId};
} }
@ -190,7 +188,7 @@ export class CommunityComponent {
)); ));
} }
})); }));
this.countResearchResults("publication"); this.countResearchResults("publication");
this.countResearchResults("dataset"); this.countResearchResults("dataset");
this.countResearchResults("software"); this.countResearchResults("software");
@ -198,7 +196,7 @@ export class CommunityComponent {
if(this.communityId == "enermaps"){ if(this.communityId == "enermaps"){
this.countResearchResults("dataset", "enermaps::selection" ); this.countResearchResults("dataset", "enermaps::selection" );
} }
this.subs.push(this._searchCommunityProjectsService.countTotalProjects(this.properties, this.communityId).subscribe( this.subs.push(this._searchCommunityProjectsService.countTotalProjects(this.properties, this.communityId).subscribe(
projectTotal => { projectTotal => {
this.projectTotal = projectTotal; this.projectTotal = projectTotal;
@ -210,7 +208,7 @@ export class CommunityComponent {
this.projectsCalculated = true; this.projectsCalculated = true;
} }
)); ));
this.subs.push(this._searchCommunityDataprovidersService.countTotalDataproviders(this.properties, this.communityId).subscribe( this.subs.push(this._searchCommunityDataprovidersService.countTotalDataproviders(this.properties, this.communityId).subscribe(
contentProviderTotal => { contentProviderTotal => {
this.contentProviderTotal = contentProviderTotal; this.contentProviderTotal = contentProviderTotal;
@ -233,10 +231,10 @@ export class CommunityComponent {
} }
)); ));
} }
private searchPublications(page: number, size: number) { private searchPublications(page: number, size: number) {
this.setActiveTab("publication"); this.setActiveTab("publication");
if (this.reloadPublications && if (this.reloadPublications &&
(this.fetchPublications.searchUtils.status == this.errorCodes.LOADING || (this.fetchPublications.searchUtils.status == this.errorCodes.LOADING ||
(this.fetchPublications.searchUtils.status == this.errorCodes.DONE && this.fetchPublications.searchUtils.totalResults > 0) (this.fetchPublications.searchUtils.status == this.errorCodes.DONE && this.fetchPublications.searchUtils.totalResults > 0)
@ -246,10 +244,10 @@ export class CommunityComponent {
} }
this.reloadPublications = false; this.reloadPublications = false;
} }
private searchDatasets(page: number, size: number) { private searchDatasets(page: number, size: number) {
this.setActiveTab("dataset"); this.setActiveTab("dataset");
if (this.reloadDatasets && if (this.reloadDatasets &&
(this.fetchDatasets.searchUtils.status == this.errorCodes.LOADING || (this.fetchDatasets.searchUtils.status == this.errorCodes.LOADING ||
(this.fetchDatasets.searchUtils.status == this.errorCodes.DONE && this.fetchDatasets.searchUtils.totalResults > 0) (this.fetchDatasets.searchUtils.status == this.errorCodes.DONE && this.fetchDatasets.searchUtils.totalResults > 0)
@ -259,10 +257,10 @@ export class CommunityComponent {
} }
this.reloadDatasets = false; this.reloadDatasets = false;
} }
private searchSoftware(page: number, size: number) { private searchSoftware(page: number, size: number) {
this.setActiveTab("software"); this.setActiveTab("software");
if (this.reloadSoftware && if (this.reloadSoftware &&
(this.fetchSoftware.searchUtils.status == this.errorCodes.LOADING || (this.fetchSoftware.searchUtils.status == this.errorCodes.LOADING ||
(this.fetchSoftware.searchUtils.status == this.errorCodes.DONE && this.fetchSoftware.searchUtils.totalResults > 0) (this.fetchSoftware.searchUtils.status == this.errorCodes.DONE && this.fetchSoftware.searchUtils.totalResults > 0)
@ -272,10 +270,10 @@ export class CommunityComponent {
} }
this.reloadSoftware = false; this.reloadSoftware = false;
} }
private searchOrps(page: number, size: number) { private searchOrps(page: number, size: number) {
this.setActiveTab("other"); this.setActiveTab("other");
if (this.reloadOrps && if (this.reloadOrps &&
(this.fetchOrps.searchUtils.status == this.errorCodes.LOADING || (this.fetchOrps.searchUtils.status == this.errorCodes.LOADING ||
(this.fetchOrps.searchUtils.status == this.errorCodes.DONE && this.fetchOrps.searchUtils.totalResults > 0) (this.fetchOrps.searchUtils.status == this.errorCodes.DONE && this.fetchOrps.searchUtils.totalResults > 0)
@ -296,10 +294,10 @@ export class CommunityComponent {
} }
this.reloadFeaturedDatasets = false; this.reloadFeaturedDatasets = false;
} }
private countResearchResults(resultType: string, contextId = null) { private countResearchResults(resultType: string, contextId = null) {
let fetch: FetchResearchResults; let fetch: FetchResearchResults;
if (resultType == "publication") { if (resultType == "publication") {
fetch = this.fetchPublications; fetch = this.fetchPublications;
} else if (resultType == "dataset" && !contextId) { } else if (resultType == "dataset" && !contextId) {
@ -315,7 +313,7 @@ export class CommunityComponent {
} }
fetch.getNumForCommunity(resultType, this.communityId, this.properties, contextId); fetch.getNumForCommunity(resultType, this.communityId, this.properties, contextId);
} }
public ngOnDestroy() { public ngOnDestroy() {
for (let sub of this.subs) { for (let sub of this.subs) {
sub.unsubscribe(); sub.unsubscribe();
@ -326,19 +324,19 @@ export class CommunityComponent {
this.fetchSoftware.clearSubscriptions(); this.fetchSoftware.clearSubscriptions();
this.fetchFeaturedDatasets.clearSubscriptions(); this.fetchFeaturedDatasets.clearSubscriptions();
} }
isEntityEnabled(entity: string) { isEntityEnabled(entity: string) {
return this.communityInfo.entities.some(x => x['pid'] == entity && x['isEnabled'] === true); return this.communityInfo.entities.some(x => x['pid'] == entity && x['isEnabled'] === true);
} }
isRouteEnabled(route: string) { isRouteEnabled(route: string) {
return this.communityInfo.pages.some(x => x['route'] == route && x['isEnabled'] === true); return this.communityInfo.pages.some(x => x['route'] == route && x['isEnabled'] === true);
} }
showInvite() { showInvite() {
return this.isManager(); return this.isManager();
} }
isManager() { isManager() {
if (!this.user) { if (!this.user) {
return false; return false;
@ -350,11 +348,11 @@ export class CommunityComponent {
} }
return Session.isPortalAdministrator(this.user) || Session.isCommunityCurator(this.user) || index != -1; return Session.isPortalAdministrator(this.user) || Session.isCommunityCurator(this.user) || index != -1;
} }
private handleError(message: string, error) { private handleError(message: string, error) {
console.error("Community (component): " + message, error); console.error("Community (component): " + message, error);
} }
getSearchPlaceHolder() { getSearchPlaceHolder() {
var entities = []; var entities = [];
if (this.isEntityEnabled("publication")) { if (this.isEntityEnabled("publication")) {
@ -371,7 +369,7 @@ export class CommunityComponent {
} }
return "Search" + ((entities.length > 0) ? (" for " + entities.join(', ') + "...") : ""); return "Search" + ((entities.length > 0) ? (" for " + entities.join(', ') + "...") : "");
} }
countOtherGraphs() { countOtherGraphs() {
var count = 0; var count = 0;
if (this.statistics && this.statistics.allowedEntities) { if (this.statistics && this.statistics.allowedEntities) {
@ -383,11 +381,11 @@ export class CommunityComponent {
} }
return count; return count;
} }
createParams(param) { createParams(param) {
return StringUtils.quote(StringUtils.URIEncode(param)); return StringUtils.quote(StringUtils.URIEncode(param));
} }
private setActiveTab(entityType: string) { private setActiveTab(entityType: string) {
if (entityType == "other") { if (entityType == "other") {
this.activeTab = "orp"; this.activeTab = "orp";
@ -395,7 +393,7 @@ export class CommunityComponent {
this.activeTab = entityType; this.activeTab = entityType;
} }
} }
public getParamsForSearchLink(type: string = "") { public getParamsForSearchLink(type: string = "") {
if (type) { if (type) {
return this.routerHelper.createQueryParams(['type', 'qf', 'sortBy'], [type, 'false', 'resultdateofacceptance,descending']); return this.routerHelper.createQueryParams(['type', 'qf', 'sortBy'], [type, 'false', 'resultdateofacceptance,descending']);
@ -403,7 +401,7 @@ export class CommunityComponent {
return {}; return {};
} }
} }
private getEntityName(entityType: string, plural: boolean, full: boolean): string { private getEntityName(entityType: string, plural: boolean, full: boolean): string {
if (entityType == "publication") { if (entityType == "publication") {
return "publication" + (plural ? "s" : ""); return "publication" + (plural ? "s" : "");
@ -415,10 +413,10 @@ export class CommunityComponent {
return (full ? ("other research product" + (plural ? "s" : "")) : "other"); return (full ? ("other research product" + (plural ? "s" : "")) : "other");
} }
} }
public buildProjectsAndContentProvidesTooltip(): string { public buildProjectsAndContentProvidesTooltip(): string {
let tooltipContent: string = "<div class='uk-margin'>"; let tooltipContent: string = "<div class='uk-margin'>";
if (this.projectTotal != null && this.projectTotal > 0 && this.isEntityEnabled('project') && this.isRouteEnabled(this.searchLinkToProjects)) { if (this.projectTotal != null && this.projectTotal > 0 && this.isEntityEnabled('project') && this.isRouteEnabled(this.searchLinkToProjects)) {
tooltipContent += "<span class='uk-text-bold'>Projects</span>"; tooltipContent += "<span class='uk-text-bold'>Projects</span>";
} }
@ -429,22 +427,22 @@ export class CommunityComponent {
if (this.contentProviderTotal != null && this.contentProviderTotal > 0 && this.isEntityEnabled('datasource') && this.isRouteEnabled(this.searchLinkToDataProviders)) { if (this.contentProviderTotal != null && this.contentProviderTotal > 0 && this.isEntityEnabled('datasource') && this.isRouteEnabled(this.searchLinkToDataProviders)) {
tooltipContent += "<span class='uk-text-bold'>Content Providers</span>"; tooltipContent += "<span class='uk-text-bold'>Content Providers</span>";
} }
tooltipContent += " have been selected as relevant for your community by the gateway curators."; tooltipContent += " have been selected as relevant for your community by the gateway curators.";
tooltipContent += "</div>"; tooltipContent += "</div>";
return tooltipContent; return tooltipContent;
} }
public buildZenodoCommunitiesTooltip(): string { public buildZenodoCommunitiesTooltip(): string {
let tooltipContent: string = "<div class='uk-margin'>"; let tooltipContent: string = "<div class='uk-margin'>";
tooltipContent += "<span class='uk-text-bold'>Zenodo</span> is a catch-all repository for OpenAIRE."; tooltipContent += "<span class='uk-text-bold'>Zenodo</span> is a catch-all repository for OpenAIRE.";
tooltipContent += "<div class='uk-margin-small-top'>A <span class='uk-text-bold'>Zenodo Community</span> is created and curated by Zenodo users.</div>"; tooltipContent += "<div class='uk-margin-small-top'>A <span class='uk-text-bold'>Zenodo Community</span> is created and curated by Zenodo users.</div>";
tooltipContent += "</div>"; tooltipContent += "</div>";
return tooltipContent; return tooltipContent;
} }
entityChanged($event) { entityChanged($event) {
this.selectedEntity = $event.entity; this.selectedEntity = $event.entity;
this.selectedEntitySimpleUrl = $event.simpleUrl; this.selectedEntitySimpleUrl = $event.simpleUrl;
@ -459,7 +457,7 @@ export class CommunityComponent {
this.placeholderText = "Search community content"; this.placeholderText = "Search community content";
} }
} }
goTo(simple: boolean) { goTo(simple: boolean) {
let url = (simple) ? this.selectedEntitySimpleUrl : this.selectedEntityAdvancedUrl; let url = (simple) ? this.selectedEntitySimpleUrl : this.selectedEntityAdvancedUrl;
let parameterNames = []; let parameterNames = [];
@ -478,11 +476,11 @@ export class CommunityComponent {
} }
this._router.navigate([url], {queryParams: this.routerHelper.createQueryParams(parameterNames, parameterValues)}); this._router.navigate([url], {queryParams: this.routerHelper.createQueryParams(parameterNames, parameterValues)});
} }
public countSubscribersEvent($event) { public countSubscribersEvent($event) {
this.subscribers = $event.value; this.subscribers = $event.value;
} }
public checkStatistics(type: string) { public checkStatistics(type: string) {
return !!(this.isEntityEnabled(type) return !!(this.isEntityEnabled(type)
&& this.statistics && this.statistics.statisticsDisplay && this.statistics.statisticsDisplay.isActive && this.statistics && this.statistics.statisticsDisplay && this.statistics.statisticsDisplay.isActive
@ -498,7 +496,7 @@ export class CommunityComponent {
&& this.statistics.allowedChartsMode['showInMonitor'][type] && this.statistics.allowedChartsMode['showInMonitor'][type]
&& this.statistics.allowedChartsMode['showInMonitor'][type].length > 0))); && this.statistics.allowedChartsMode['showInMonitor'][type].length > 0)));
} }
public initializeAnalyticsActiveTab() { public initializeAnalyticsActiveTab() {
if (!this.analyticsChecked) { if (!this.analyticsChecked) {
if (this.checkStatistics("publication")) { if (this.checkStatistics("publication")) {
@ -512,12 +510,12 @@ export class CommunityComponent {
} }
} }
} }
public showAnalyticsTab() { public showAnalyticsTab() {
this.initializeAnalyticsActiveTab(); this.initializeAnalyticsActiveTab();
return this.analyticsActiveTab; return this.analyticsActiveTab;
} }
public onSelectActiveTab(activeTabId) { public onSelectActiveTab(activeTabId) {
if (this.activeTab != "activaTabId") { // tab really changed if (this.activeTab != "activaTabId") { // tab really changed
if (activeTabId == 'summary') { if (activeTabId == 'summary') {
@ -543,7 +541,7 @@ export class CommunityComponent {
this.activeTab = 'mapping'; this.activeTab = 'mapping';
} else if (activeTabId == 'enermaps') { } else if (activeTabId == 'enermaps') {
this.show = 'enermaps'; this.show = 'enermaps';
this.searchFeaturedDatasets(1, this.fetchFeaturedDatasets.searchUtils.totalResults < 20?this.fetchFeaturedDatasets.searchUtils.totalResults:20); this.searchFeaturedDatasets(1, this.fetchFeaturedDatasets.searchUtils.totalResults);
} }
} }
} }