From 82cec11525a6cdd715ce1887237452ed3a624457 Mon Sep 17 00:00:00 2001 From: "konstantina.galouni" Date: Wed, 21 Sep 2022 15:39:57 +0300 Subject: [PATCH] [Library | new-theme]: dataProvider.component.ts & project.component.ts & resultLanding.component.ts: Small update on previous commit - Call detectChanges() method, after content is returned and processed, right after showLoading = false command. --- landingPages/dataProvider/dataProvider.component.ts | 2 +- landingPages/project/project.component.ts | 2 +- landingPages/result/resultLanding.component.ts | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/landingPages/dataProvider/dataProvider.component.ts b/landingPages/dataProvider/dataProvider.component.ts index 9f9e14b3..cf833781 100644 --- a/landingPages/dataProvider/dataProvider.component.ts +++ b/landingPages/dataProvider/dataProvider.component.ts @@ -340,7 +340,6 @@ export class DataProviderComponent { } else { this.subscriptions.push(this._dataproviderService.getDataproviderInfo(this.datasourceId, this.identifier, this.properties, this.typeQueryPathParam).subscribe( data => { - this.cdr.detectChanges(); this.dataProviderInfo = data; this.getProvenanceUrls(); this.datasourceId = this.dataProviderInfo.objIdentifier; @@ -367,6 +366,7 @@ export class DataProviderComponent { } this.showLoading = false; + this.cdr.detectChanges(); // if (this.dataProviderInfo.tabs != undefined && this.dataProviderInfo.tabs.length > 0) { // this.activeTab = this.dataProviderInfo.tabs[0].name; diff --git a/landingPages/project/project.component.ts b/landingPages/project/project.component.ts index 2cb83d66..a7da88da 100644 --- a/landingPages/project/project.component.ts +++ b/landingPages/project/project.component.ts @@ -474,7 +474,6 @@ export class ProjectComponent { } actionsAfterGettingProjectInfo() { - this.cdr.detectChanges(); this.projectName = this.projectInfo.acronym; if (this.projectName == undefined || this.projectName == '') { this.projectName = this.projectInfo.title; @@ -521,6 +520,7 @@ export class ProjectComponent { } this.showLoading = false; + this.cdr.detectChanges(); } public downloadCsvFile(url: string, filename: string) { diff --git a/landingPages/result/resultLanding.component.ts b/landingPages/result/resultLanding.component.ts index bfe9f6b5..401261b1 100644 --- a/landingPages/result/resultLanding.component.ts +++ b/landingPages/result/resultLanding.component.ts @@ -447,7 +447,6 @@ export class ResultLandingComponent { this.hasAltMetrics = false; this.subscriptions.push(this._resultLandingService.getResultLandingInfo(this.id, this.identifier, this.type, subjectsVocabulary, this.properties).subscribe( data => { - this.cdr.detectChanges(); this.resultLandingInfo = data; this.id = this.resultLandingInfo.objIdentifier; //old