[Library]: Fixes in ORCID put-codes query & query dynamic menu only in development environment.
1. dataProvider.component.ts: Comment log for dataProviderInfo.fundedContent. 2. searchResult.component.ts: In initialize() method, before calling orcidService.getPutCodes, added more checks for type (result, publication, dataset, software, other). 3. navigationBar.component.ts: Call _helpContentService.getMenuItems only in development environment.
This commit is contained in:
parent
dccf62d445
commit
304276f3bc
|
@ -290,7 +290,7 @@ export class DataProviderComponent {
|
|||
this.subscriptions.push(this._searchResearchResultsService.countCollectedResultsWithFundingInfo(this.datasourceId).subscribe(
|
||||
fundedContent => {
|
||||
this.dataProviderInfo.fundedContent = fundedContent;
|
||||
console.log(this.dataProviderInfo.fundedContent);
|
||||
// console.log(this.dataProviderInfo.fundedContent);
|
||||
},
|
||||
err => {
|
||||
this.handleError("Error getting results with funding information for datasource id: " + this.datasourceId, err);
|
||||
|
|
|
@ -42,7 +42,9 @@ export class SearchResultComponent implements OnInit, OnChanges {
|
|||
}
|
||||
|
||||
if((properties.adminToolsPortalType == "explore" || properties.adminToolsPortalType == "community")
|
||||
&& Session.isLoggedIn() && this.results && this.results.length > 0) {
|
||||
&& Session.isLoggedIn() && this.results && this.results.length > 0
|
||||
&& (this.type == "result" || this.type == "publication" || this.type == "dataset" || this.type == "software" || this.type == "other")
|
||||
) {
|
||||
this.orcidService.getPutCodes(this.previewResults.map(
|
||||
previewResult => {
|
||||
if(previewResult.identifiers) {
|
||||
|
|
|
@ -103,7 +103,7 @@ export class NavigationBarComponent implements OnInit, OnDestroy {
|
|||
this.handleError('Error getting community information (e.g. pages,entities) for community with id: ' + this.communityId, error);
|
||||
}));
|
||||
}
|
||||
if(this.portal != 'connect' && this.portal != 'connect-admin' && this.properties.adminToolsPortalType == 'community') {
|
||||
if(this.properties.environment == "development" && this.portal != 'connect' && this.portal != 'connect-admin' && this.properties.adminToolsPortalType == 'community') {
|
||||
this.subs.push(
|
||||
this._helpContentService.getMenuItems(this.portal).subscribe(
|
||||
data => {
|
||||
|
|
Loading…
Reference in New Issue