Merge pull request 'Production release November 2023 v3' (#23) from develop into master
Reviewed-on: #23
This commit is contained in:
commit
1a7624eed1
|
@ -394,8 +394,8 @@ export class DataProviderComponent {
|
||||||
this.updateUrl(this.canonicalUrl);
|
this.updateUrl(this.canonicalUrl);
|
||||||
this.seoService.createLinkForCanonicalURL(this.properties.domain +this.properties.baseLink + this._router.url);
|
this.seoService.createLinkForCanonicalURL(this.properties.domain +this.properties.baseLink + this._router.url);
|
||||||
if (typeof document !== 'undefined') {
|
if (typeof document !== 'undefined') {
|
||||||
this.getDataProviderAggregationStatus(this.dataProviderInfo.originalId);
|
// this.getDataProviderAggregationStatus(this.dataProviderInfo.originalId);
|
||||||
// this.getCollectedFulltexts();
|
this.getCollectedFulltexts();
|
||||||
this.countResultsWithFundingInfo();
|
this.countResultsWithFundingInfo();
|
||||||
} else {
|
} else {
|
||||||
this.aggregationStatusIsInitialized = true;
|
this.aggregationStatusIsInitialized = true;
|
||||||
|
@ -454,34 +454,34 @@ export class DataProviderComponent {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private getDataProviderAggregationStatus(originalId: string) {
|
// private getDataProviderAggregationStatus(originalId: string) {
|
||||||
this.subscriptions.push(this._dataproviderService.getDataproviderAggregationStatus(originalId, this.properties).subscribe(
|
// this.subscriptions.push(this._dataproviderService.getDataproviderAggregationStatus(originalId, this.properties).subscribe(
|
||||||
data => {
|
// data => {
|
||||||
this.dataProviderInfo.aggregationStatus = data;
|
// this.dataProviderInfo.aggregationStatus = data;
|
||||||
this.aggregationStatusIsInitialized = true;
|
|
||||||
},
|
|
||||||
err => {
|
|
||||||
//console.log(err);
|
|
||||||
this.aggregationStatusIsInitialized = true;
|
|
||||||
this.handleError("Error getting "+this.getTypeName()+" aggregation status for id: " + this.datasourceId, err);
|
|
||||||
}
|
|
||||||
));
|
|
||||||
}
|
|
||||||
|
|
||||||
// private getCollectedFulltexts() {
|
|
||||||
// this.subscriptions.push(this._dataproviderService.getCollectedFulltexts(this.datasourceId).subscribe(
|
|
||||||
// (data: string) => {
|
|
||||||
// this.dataProviderInfo.aggregationStatus = {"fulltexts": data};
|
|
||||||
// this.aggregationStatusIsInitialized = true;
|
// this.aggregationStatusIsInitialized = true;
|
||||||
// },
|
// },
|
||||||
// err => {
|
// err => {
|
||||||
// //console.log(err);
|
// //console.log(err);
|
||||||
// this.aggregationStatusIsInitialized = true;
|
// this.aggregationStatusIsInitialized = true;
|
||||||
// this.handleError("Error getting "+this.getTypeName()+" collected fulltexts for id: " + this.datasourceId, err);
|
// this.handleError("Error getting "+this.getTypeName()+" aggregation status for id: " + this.datasourceId, err);
|
||||||
// }
|
// }
|
||||||
// ));
|
// ));
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
private getCollectedFulltexts() {
|
||||||
|
this.subscriptions.push(this._dataproviderService.getCollectedFulltexts(this.datasourceId).subscribe(
|
||||||
|
(data: string) => {
|
||||||
|
this.dataProviderInfo.aggregationStatus = {"fulltexts": data};
|
||||||
|
this.aggregationStatusIsInitialized = true;
|
||||||
|
},
|
||||||
|
err => {
|
||||||
|
//console.log(err);
|
||||||
|
this.aggregationStatusIsInitialized = true;
|
||||||
|
this.handleError("Error getting "+this.getTypeName()+" collected fulltexts for id: " + this.datasourceId, err);
|
||||||
|
}
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
private countResultsWithFundingInfo() {
|
private countResultsWithFundingInfo() {
|
||||||
this.subscriptions.push(this._searchResearchResultsService.countCollectedResultsWithFundingInfo(this.datasourceId).subscribe(
|
this.subscriptions.push(this._searchResearchResultsService.countCollectedResultsWithFundingInfo(this.datasourceId).subscribe(
|
||||||
fundedContent => {
|
fundedContent => {
|
||||||
|
|
|
@ -83,10 +83,10 @@ export class DataProviderService {
|
||||||
.pipe(map(res => this.parseDataproviderAggregationStatus(res)));
|
.pipe(map(res => this.parseDataproviderAggregationStatus(res)));
|
||||||
}
|
}
|
||||||
|
|
||||||
// getCollectedFulltexts(datasourceId: string) {
|
getCollectedFulltexts(datasourceId: string) {
|
||||||
// return this.http.get(properties.pdfStatisticsAPIURL+"/api/stats/getNumberOfPayloadsForDatasource?datasourceId="+datasourceId)
|
return this.http.get(properties.pdfStatisticsAPIURL+"/stats/getNumberOfPayloadsForDatasource?datasourceId="+datasourceId)
|
||||||
// .pipe(map(res => res))
|
.pipe(map(res => res))
|
||||||
// }
|
}
|
||||||
|
|
||||||
private handleError (error: HttpErrorResponse) {
|
private handleError (error: HttpErrorResponse) {
|
||||||
// in a real world app, we may send the error to some remote logging infrastructure
|
// in a real world app, we may send the error to some remote logging infrastructure
|
||||||
|
|
|
@ -894,7 +894,7 @@ export class ParsingFunctions {
|
||||||
countsPerDatasource[datasourcePosition.get(element.datasource)].views = element.count;
|
countsPerDatasource[datasourcePosition.get(element.datasource)].views = element.count;
|
||||||
} else {
|
} else {
|
||||||
datasourcePosition.set(element.datasource, countsPerDatasource.length);
|
datasourcePosition.set(element.datasource, countsPerDatasource.length);
|
||||||
countsPerDatasource.push({"datasourceId": element.datasource, "views": element.count, "downloads": 0})
|
countsPerDatasource.push({"datasourceId": element.datasource.split("||")[0], "datasourceName": element.datasource.split("||")[1], "views": element.count, "downloads": 0})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// measure.views = element.count;
|
// measure.views = element.count;
|
||||||
|
@ -907,7 +907,7 @@ export class ParsingFunctions {
|
||||||
countsPerDatasource[datasourcePosition.get(element.datasource)].downloads = element.count;
|
countsPerDatasource[datasourcePosition.get(element.datasource)].downloads = element.count;
|
||||||
} else {
|
} else {
|
||||||
datasourcePosition.set(element.datasource, countsPerDatasource.length);
|
datasourcePosition.set(element.datasource, countsPerDatasource.length);
|
||||||
countsPerDatasource.push({"datasourceId": element.datasource, "views": 0, "downloads": element.count})
|
countsPerDatasource.push({"datasourceId": element.datasource.split("||")[0], "datasourceName": element.datasource.split("||")[1], "views": 0, "downloads": element.count})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// measure.downloads = element.count;
|
// measure.downloads = element.count;
|
||||||
|
|
|
@ -297,13 +297,13 @@
|
||||||
<my-tab *ngIf="resultLandingInfo.bioentities && bioentitiesNum> 0"
|
<my-tab *ngIf="resultLandingInfo.bioentities && bioentitiesNum> 0"
|
||||||
[tabTitle]="'External Databases'" [tabId]="'bioentities'" [tabNumber]="bioentitiesNum">
|
[tabTitle]="'External Databases'" [tabId]="'bioentities'" [tabNumber]="bioentitiesNum">
|
||||||
</my-tab>
|
</my-tab>
|
||||||
|
<my-tab *ngIf="resultLandingInfo && (resultLandingInfo.measure || hasAltMetrics)"
|
||||||
|
[tabTitle]="'Metrics'" [tabId]="'metrics'">
|
||||||
|
</my-tab>
|
||||||
<my-tab *ngIf="enermapsId && properties.enermapsURL"
|
<my-tab *ngIf="enermapsId && properties.enermapsURL"
|
||||||
[tabTitle]="'Enermaps Tool'" [tabId]="'enermaps'"
|
[tabTitle]="'Enermaps Tool'" [tabId]="'enermaps'"
|
||||||
customClass="portalTab">
|
customClass="portalTab">
|
||||||
</my-tab>
|
</my-tab>
|
||||||
<my-tab *ngIf="resultLandingInfo && (resultLandingInfo.measure || hasAltMetrics)"
|
|
||||||
[tabTitle]="'Metrics'" [tabId]="'metrics'">
|
|
||||||
</my-tab>
|
|
||||||
</my-tabs>
|
</my-tabs>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -328,14 +328,14 @@
|
||||||
<ng-container *ngTemplateOutlet="bioentities_content"></ng-container>
|
<ng-container *ngTemplateOutlet="bioentities_content"></ng-container>
|
||||||
</div>
|
</div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
|
<ng-container *ngIf="resultLandingInfo && ((resultLandingInfo.measure && (resultLandingInfo.measure.bip.length || resultLandingInfo.measure.counts.length)) || hasAltMetrics)">
|
||||||
|
<ng-container *ngTemplateOutlet="metricsContent"></ng-container>
|
||||||
|
</ng-container>
|
||||||
<ng-container *ngIf="enermapsId && properties.enermapsURL">
|
<ng-container *ngIf="enermapsId && properties.enermapsURL">
|
||||||
<div id="enermaps" class="landing-section">
|
<div id="enermaps" class="landing-section">
|
||||||
<ng-container *ngTemplateOutlet="enermapsTool_content"></ng-container>
|
<ng-container *ngTemplateOutlet="enermapsTool_content"></ng-container>
|
||||||
</div>
|
</div>
|
||||||
</ng-container>
|
</ng-container>
|
||||||
<ng-container *ngIf="resultLandingInfo && ((resultLandingInfo.measure && (resultLandingInfo.measure.bip.length || resultLandingInfo.measure.counts.length)) || hasAltMetrics)">
|
|
||||||
<ng-container *ngTemplateOutlet="metricsContent"></ng-container>
|
|
||||||
</ng-container>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="uk-text-xsmall uk-hidden@m"><ng-container *ngTemplateOutlet="graph_and_feedback_template"></ng-container></div>
|
<div class="uk-text-xsmall uk-hidden@m"><ng-container *ngTemplateOutlet="graph_and_feedback_template"></ng-container></div>
|
||||||
<helper *ngIf="pageContents && pageContents['bottom'] && pageContents['bottom'].length > 0"
|
<helper *ngIf="pageContents && pageContents['bottom'] && pageContents['bottom'].length > 0"
|
||||||
|
@ -1251,7 +1251,7 @@
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr *ngFor="let datasource of resultLandingInfo.measure.countsPerDatasource">
|
<tr *ngFor="let datasource of resultLandingInfo.measure.countsPerDatasource">
|
||||||
<td class="uk-text-truncate"><a [routerLink]="properties.searchLinkToDataProvider.split('?')[0]" [queryParams]="{'datasourceId': datasource.datasourceId}">{{datasource.datasourceId}}</a></td>
|
<td class="uk-text-truncate"><a [routerLink]="properties.searchLinkToDataProvider.split('?')[0]" [queryParams]="{'datasourceId': datasource.datasourceId}">{{datasource.datasourceName}}</a></td>
|
||||||
<td class="uk-text-center">{{datasource.views}}</td>
|
<td class="uk-text-center">{{datasource.views}}</td>
|
||||||
<td class="uk-text-center">{{datasource.downloads}}</td>
|
<td class="uk-text-center">{{datasource.downloads}}</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
|
@ -554,10 +554,6 @@ export class ResultLandingComponent {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this.communityId && this.communityId == "enermaps" && properties.enermapsURL) {
|
|
||||||
this.enermapsId = ParsingFunctions.getEnermapsConceptId(this.resultLandingInfo.contexts);
|
|
||||||
}
|
|
||||||
|
|
||||||
this.relatedClassFilters = [{"label": "All relations", "value": ""}];
|
this.relatedClassFilters = [{"label": "All relations", "value": ""}];
|
||||||
if (this.resultLandingInfo.relatedClassFilters.size > 1) {
|
if (this.resultLandingInfo.relatedClassFilters.size > 1) {
|
||||||
for (let relClass of this.resultLandingInfo.relatedClassFilters) {
|
for (let relClass of this.resultLandingInfo.relatedClassFilters) {
|
||||||
|
@ -591,6 +587,9 @@ export class ResultLandingComponent {
|
||||||
this.cdr.detectChanges();
|
this.cdr.detectChanges();
|
||||||
|
|
||||||
if (contexts) {
|
if (contexts) {
|
||||||
|
if (this.communityId && this.communityId == "enermaps" && properties.enermapsURL) {
|
||||||
|
this.enermapsId = ParsingFunctions.getEnermapsConceptId(contexts);
|
||||||
|
}
|
||||||
await this.promise;
|
await this.promise;
|
||||||
if(this.publicCommunities && this.publicCommunities.length > 0) {
|
if(this.publicCommunities && this.publicCommunities.length > 0) {
|
||||||
this.resultLandingInfo.contexts = contexts.filter(context => {
|
this.resultLandingInfo.contexts = contexts.filter(context => {
|
||||||
|
|
|
@ -1,53 +0,0 @@
|
||||||
@import (reference) "~src/assets/openaire-theme/less/_import-variables";
|
|
||||||
|
|
||||||
.number-preview {
|
|
||||||
border: @global-border-width solid @global-border;
|
|
||||||
background: transparent;
|
|
||||||
border-radius: @global-border-radius;
|
|
||||||
min-width: 100px;
|
|
||||||
min-height: 70px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.refresh-indicator {
|
|
||||||
background-color: @global-overlay-background;
|
|
||||||
border-radius: @global-border-radius;
|
|
||||||
position: absolute;
|
|
||||||
color: @global-inverse-color;
|
|
||||||
z-index: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.section {
|
|
||||||
padding: 60px 45px;
|
|
||||||
border-radius: @global-border-radius;
|
|
||||||
border: @global-border-width solid @global-border;
|
|
||||||
position: relative;
|
|
||||||
background: @global-inverse-color;
|
|
||||||
border-left: 5px @global-primary-background solid;
|
|
||||||
|
|
||||||
.tools {
|
|
||||||
position: absolute;
|
|
||||||
top: 0;
|
|
||||||
left: 50%;
|
|
||||||
transform: translate(-50%, -100%);
|
|
||||||
max-width: 50px;
|
|
||||||
padding: 5px 10px;
|
|
||||||
background-image: @global-primary-gradient;
|
|
||||||
color: @global-inverse-color;
|
|
||||||
-webkit-clip-path: polygon(20% 5%, 80% 5%, 100% 100%, 0% 100%);
|
|
||||||
clip-path: polygon(20% 5%, 80% 5%, 100% 100%, 0% 100%);
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
&:hover {
|
|
||||||
.tools {
|
|
||||||
display: block;
|
|
||||||
|
|
||||||
a {
|
|
||||||
color: currentColor;
|
|
||||||
&:hover {
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -51,8 +51,7 @@ declare var UIkit;
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'indicators',
|
selector: 'indicators',
|
||||||
templateUrl: './indicators.component.html',
|
templateUrl: './indicators.component.html'
|
||||||
styleUrls: ['indicators.component.less']
|
|
||||||
})
|
})
|
||||||
export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterViewInit {
|
export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterViewInit {
|
||||||
filesToUpload: Array<File>;
|
filesToUpload: Array<File>;
|
||||||
|
|
|
@ -40,7 +40,7 @@ export class EntitiesSelectionComponent {
|
||||||
|
|
||||||
/** TODO change conditions base on PortalType instead of customFilter */
|
/** TODO change conditions base on PortalType instead of customFilter */
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
if ((this.customFilter && this.customFilter.queryFieldName == "communityId") || (['explore', 'aggregator', 'eosc'].includes(this.properties.adminToolsPortalType))) {
|
if ((this.customFilter && this.customFilter.queryFieldName == "communityId") || (['explore', 'aggregator', 'eosc', 'faircore4eosc'].includes(this.properties.adminToolsPortalType))) {
|
||||||
this.subscriptions.push(this.config.portalAsObservable.subscribe(data => {
|
this.subscriptions.push(this.config.portalAsObservable.subscribe(data => {
|
||||||
if (data) {
|
if (data) {
|
||||||
let showEntity = {};
|
let showEntity = {};
|
||||||
|
|
|
@ -20,8 +20,7 @@ export class SearchSortingComponent {
|
||||||
@Input() entityType: string = '';
|
@Input() entityType: string = '';
|
||||||
@Output() sortByChange = new EventEmitter();
|
@Output() sortByChange = new EventEmitter();
|
||||||
public options: Option[];
|
public options: Option[];
|
||||||
private generalOptions = properties.environment != "production" ?
|
private generalOptions = [
|
||||||
[
|
|
||||||
{value: '', label: 'Relevance'},
|
{value: '', label: 'Relevance'},
|
||||||
{value: 'resultdateofacceptance,descending', label: 'Date (most recent)'},
|
{value: 'resultdateofacceptance,descending', label: 'Date (most recent)'},
|
||||||
{value: 'resultdateofacceptance,ascending', label: 'Date (least recent)'},
|
{value: 'resultdateofacceptance,ascending', label: 'Date (least recent)'},
|
||||||
|
@ -29,11 +28,6 @@ export class SearchSortingComponent {
|
||||||
{value: 'popularity,descending', label: 'Popularity'},
|
{value: 'popularity,descending', label: 'Popularity'},
|
||||||
{value: 'influence,descending', label: 'Influence'},
|
{value: 'influence,descending', label: 'Influence'},
|
||||||
{value: 'impulse,descending', label: 'Impulse'}
|
{value: 'impulse,descending', label: 'Impulse'}
|
||||||
] :
|
|
||||||
[
|
|
||||||
{value: '', label: 'Relevance'},
|
|
||||||
{value: 'resultdateofacceptance,descending', label: 'Date (most recent)'},
|
|
||||||
{value: 'resultdateofacceptance,ascending', label: 'Date (least recent)'}
|
|
||||||
];
|
];
|
||||||
private communityOptions = [
|
private communityOptions = [
|
||||||
{value: '', label: 'Title'},
|
{value: '', label: 'Title'},
|
||||||
|
|
|
@ -26,11 +26,32 @@ export class RefineFieldResultsService {
|
||||||
.pipe(map(res => [res['meta'].total, RefineResultsUtils.parse(res['refineResults'],fields, entityName)]));
|
.pipe(map(res => [res['meta'].total, RefineResultsUtils.parse(res['refineResults'],fields, entityName)]));
|
||||||
|
|
||||||
}
|
}
|
||||||
getRefineFieldResultsByFieldName(fieldName:string, entityName:string, properties:EnvProperties):any{
|
|
||||||
let key:string="fundinglevel";
|
|
||||||
let link = properties.searchAPIURLLAst +this.getSearchAPIURLForEntity(entityName)+"?fields="+fieldName +(fieldName.toString().indexOf(key)!=-1?('&sf='+fieldName):'')+ "&format=json";
|
|
||||||
return this.getField(link,fieldName, properties);
|
|
||||||
|
|
||||||
|
getAllRefineFieldResultsByFieldName(fieldName:string, entityName:string, properties:EnvProperties, refineQuery:string=null):any{
|
||||||
|
// let keys:string[]=["funder", "relfunder", "fundinglevel"];
|
||||||
|
let url = properties.searchAPIURLLAst +this.getSearchAPIURLForEntity(entityName)+"?fields="+fieldName +('&sf='+fieldName)+ "&format=json";
|
||||||
|
if(refineQuery!= null && refineQuery != '' ) {
|
||||||
|
url += refineQuery;
|
||||||
|
}
|
||||||
|
return this.http.get((properties.useCache)? (properties.cacheUrl+encodeURIComponent(url)): url)
|
||||||
|
//.map(res => <any> res.json())
|
||||||
|
|
||||||
|
.pipe(map(res => [res['meta'].total, RefineResultsUtils.parse(res['refineResults'],[fieldName], entityName)]));
|
||||||
|
}
|
||||||
|
|
||||||
|
getRefineFieldResultsByFieldName(fieldName:string, entityName:string, properties:EnvProperties):any{
|
||||||
|
let keys:string[]=["funder", "fundinglevel"]; // this covers funder, relfunder, funding stream fields and funding level fields
|
||||||
|
let link = properties.searchAPIURLLAst +this.getSearchAPIURLForEntity(entityName)+"?fields="+fieldName +(this.fieldIncludesAnyOfTheKeywords(fieldName, keys)?('&sf='+fieldName):'')+ "&format=json";
|
||||||
|
return this.getField(link,fieldName, properties);
|
||||||
|
}
|
||||||
|
|
||||||
|
fieldIncludesAnyOfTheKeywords(field: string, keywords: string[]) {
|
||||||
|
for(let keyword of keywords) {
|
||||||
|
if(field.toString().indexOf(keyword)!=-1) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
getField (link:string,fieldName:string, properties:EnvProperties):any{
|
getField (link:string,fieldName:string, properties:EnvProperties):any{
|
||||||
|
|
|
@ -18,6 +18,7 @@ export interface Numbers {
|
||||||
softwareSize?: NumberSize;
|
softwareSize?: NumberSize;
|
||||||
otherSize?: NumberSize;
|
otherSize?: NumberSize;
|
||||||
fundersSize?: NumberSize;
|
fundersSize?: NumberSize;
|
||||||
|
mergedFundersSize?: NumberSize;
|
||||||
projectsSize?: NumberSize;
|
projectsSize?: NumberSize;
|
||||||
datasourcesSize?: NumberSize;
|
datasourcesSize?: NumberSize;
|
||||||
organizationsSize?: NumberSize;
|
organizationsSize?: NumberSize;
|
||||||
|
@ -89,6 +90,9 @@ export class NumbersComponent implements OnInit, OnDestroy {
|
||||||
this.refineValue = refineValue;
|
this.refineValue = refineValue;
|
||||||
}
|
}
|
||||||
let refineParams = (this.refineValue) ? ('&fq=' + this.refineValue) : null;
|
let refineParams = (this.refineValue) ? ('&fq=' + this.refineValue) : null;
|
||||||
|
|
||||||
|
let mergedFundersSet = new Set<string>();
|
||||||
|
|
||||||
this.subs.push(zip(
|
this.subs.push(zip(
|
||||||
(getPublications) ? this.searchResearchResultsService.numOfSearchResults('publication', '', this.properties, refineParams) : this.empty,
|
(getPublications) ? this.searchResearchResultsService.numOfSearchResults('publication', '', this.properties, refineParams) : this.empty,
|
||||||
(getDatasets) ? this.searchResearchResultsService.numOfSearchResults('dataset', '', this.properties, refineParams) : this.empty,
|
(getDatasets) ? this.searchResearchResultsService.numOfSearchResults('dataset', '', this.properties, refineParams) : this.empty,
|
||||||
|
@ -96,9 +100,10 @@ export class NumbersComponent implements OnInit, OnDestroy {
|
||||||
(getSoftware) ? this.searchResearchResultsService.numOfSearchResults('software', '', this.properties, refineParams) : this.empty,
|
(getSoftware) ? this.searchResearchResultsService.numOfSearchResults('software', '', this.properties, refineParams) : this.empty,
|
||||||
(getSoftwareLinked) ? this.searchResearchResultsService.numOfSearchResultsLinkedToPub("software", this.properties) : this.empty,
|
(getSoftwareLinked) ? this.searchResearchResultsService.numOfSearchResultsLinkedToPub("software", this.properties) : this.empty,
|
||||||
(getOther) ? this.searchResearchResultsService.numOfSearchResults('other', '', this.properties, refineParams) : this.empty,
|
(getOther) ? this.searchResearchResultsService.numOfSearchResults('other', '', this.properties, refineParams) : this.empty,
|
||||||
(getProjects) ? this.refineFieldResultsService.getRefineFieldsResultsByEntityName(['funder'], 'project', this.properties, refineParams) : this.empty,
|
(getProjects) ? this.refineFieldResultsService.getAllRefineFieldResultsByFieldName('funder', 'project', this.properties, refineParams) : this.empty,
|
||||||
(getDataProviders) ? this.searchDataprovidersService.numOfSearchDataproviders('', this.properties, refineParams) : this.empty,
|
(getDataProviders) ? this.searchDataprovidersService.numOfSearchDataproviders('', this.properties, refineParams) : this.empty,
|
||||||
(getOrganizations) ? this._searchOrganizationsService.numOfSearchOrganizations2('', this.properties, refineParams) : this.empty
|
(getOrganizations) ? this._searchOrganizationsService.numOfSearchOrganizations2('', this.properties, refineParams) : this.empty,
|
||||||
|
(getPublications && getDatasets && getSoftware && getOther) ? this.refineFieldResultsService.getAllRefineFieldResultsByFieldName('relfunder', 'result', this.properties, refineParams) : this.empty,
|
||||||
).subscribe((data: any[]) => {
|
).subscribe((data: any[]) => {
|
||||||
if (data[0] && data[0] > 0) {
|
if (data[0] && data[0] > 0) {
|
||||||
this.numbers.publicationsSize = NumberUtils.roundNumber(data[0]);
|
this.numbers.publicationsSize = NumberUtils.roundNumber(data[0]);
|
||||||
|
@ -123,6 +128,15 @@ export class NumbersComponent implements OnInit, OnDestroy {
|
||||||
}
|
}
|
||||||
if (data[6][1] && data[6][1].length > 0 && data[6][1][0].filterId == 'funder' && data[6][1][0].values) {
|
if (data[6][1] && data[6][1].length > 0 && data[6][1][0].filterId == 'funder' && data[6][1][0].values) {
|
||||||
this.numbers.fundersSize = NumberUtils.roundNumber(data[6][1][0].values.length);
|
this.numbers.fundersSize = NumberUtils.roundNumber(data[6][1][0].values.length);
|
||||||
|
|
||||||
|
let queriedFunders = data[6][1][0].values;
|
||||||
|
queriedFunders.forEach(queriedFunder => {
|
||||||
|
if(+queriedFunder.number > 1) {
|
||||||
|
if (!mergedFundersSet.has(queriedFunder.id)) {
|
||||||
|
mergedFundersSet.add(queriedFunder.id);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
}
|
}
|
||||||
if (data[7] && data[7] > 0) {
|
if (data[7] && data[7] > 0) {
|
||||||
this.numbers.datasourcesSize = NumberUtils.roundNumber(data[7]);
|
this.numbers.datasourcesSize = NumberUtils.roundNumber(data[7]);
|
||||||
|
@ -130,7 +144,17 @@ export class NumbersComponent implements OnInit, OnDestroy {
|
||||||
if (data[8] && data[8] > 0) {
|
if (data[8] && data[8] > 0) {
|
||||||
this.numbers.organizationsSize = NumberUtils.roundNumber(data[8]);
|
this.numbers.organizationsSize = NumberUtils.roundNumber(data[8]);
|
||||||
}
|
}
|
||||||
this.results.emit(this.numbers);
|
if (data[9][1] && data[9][1].length > 0 && data[9][1][0].filterId == 'relfunder' && data[9][1][0].values) {
|
||||||
|
let queriedFunders = data[9][1][0].values;
|
||||||
|
queriedFunders.forEach(queriedFunder => {
|
||||||
|
if (!mergedFundersSet.has(queriedFunder.id)) {
|
||||||
|
mergedFundersSet.add(queriedFunder.id);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
this.numbers.mergedFundersSize = NumberUtils.roundNumber(mergedFundersSet.size);
|
||||||
|
this.results.emit(this.numbers);
|
||||||
}, err => {
|
}, err => {
|
||||||
this.handleError('Error getting numbers', err);
|
this.handleError('Error getting numbers', err);
|
||||||
}));
|
}));
|
||||||
|
|
|
@ -49,7 +49,7 @@ export interface Measure {
|
||||||
|
|
||||||
export interface MetricPerDatasource {
|
export interface MetricPerDatasource {
|
||||||
datasourceId: string,
|
datasourceId: string,
|
||||||
// datasourceName: string,
|
datasourceName: string,
|
||||||
views: number,
|
views: number,
|
||||||
downloads: number
|
downloads: number
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,15 +31,15 @@ declare var UIkit: any;
|
||||||
<ng-content></ng-content>
|
<ng-content></ng-content>
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="(choice || okButton || cancelButton) && alertFooter" class="uk-modal-footer">
|
<div *ngIf="(choice || okButton || cancelButton) && alertFooter" class="uk-modal-footer">
|
||||||
<div class="uk-grid uk-flex uk-flex-middle" uk-grid>
|
<div class="uk-grid uk-flex uk-flex-middle uk-margin-remove-left" uk-grid>
|
||||||
<label *ngIf="choice" class="uk-width-expand">
|
<label *ngIf="choice" class="uk-width-expand">
|
||||||
<input type="checkbox" [(ngModel)]="select">
|
<input type="checkbox" [(ngModel)]="select">
|
||||||
<span class="uk-margin-small-left">Don't show this message again</span>
|
<span class="uk-margin-small-left">Don't show this message again</span>
|
||||||
</label>
|
</label>
|
||||||
<div [ngClass]="(choice)?'uk-width-auto':'uk-width-1-1'">
|
<div [ngClass]="(choice)?'uk-width-auto':'uk-width-1-1 uk-padding-remove-horizontal'">
|
||||||
<div class="uk-width-1-1" [ngClass]="(previousButton && (cancelButton || okButton)) ? 'uk-flex uk-flex-between uk-grid' : ''">
|
<div class="uk-width-1-1" [ngClass]="(previousButton && (cancelButton || okButton)) ? 'uk-flex uk-flex-between uk-grid uk-margin-remove-left' : ''">
|
||||||
<div *ngIf="previousButton" class="uk-flex-left">
|
<div *ngIf="previousButton" class="uk-flex-left uk-padding-remove-horizontal">
|
||||||
<button class="uk-button uk-button-default uk-margin-small-left"
|
<button class="uk-button uk-button-default"
|
||||||
(click)="previous()">{{previousButtonText}}</button>
|
(click)="previous()">{{previousButtonText}}</button>
|
||||||
</div>
|
</div>
|
||||||
<div class="uk-flex-right uk-grid uk-grid-small" uk-grid>
|
<div class="uk-flex-right uk-grid uk-grid-small" uk-grid>
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
|
|
||||||
export type Environment = "development" | "test" | "beta" | "production";
|
export type Environment = "development" | "test" | "beta" | "production";
|
||||||
export type Dashboard = "explore" | "connect" | "monitor" | "aggregator" | "eosc" | "developers" | "faircore4eosc";
|
export type Dashboard = "explore" | "connect" | "monitor" | "aggregator" | "eosc" | "developers" | "faircore4eosc";
|
||||||
export type PortalType = "explore" | "connect" | "community" | "monitor" | "funder" | "ri" | "project" | "organization" | "aggregator" | "eosc" | "faircore4eosc";
|
export type PortalType = "explore" | "connect" | "community" | "monitor" | "funder" | "ri" | "project" | "organization" | "aggregator" | "eosc" | "faircore4eosc";
|
||||||
|
@ -15,6 +14,7 @@ export interface EnvProperties {
|
||||||
showAddThis?: boolean;
|
showAddThis?: boolean;
|
||||||
showContent?: boolean;
|
showContent?: boolean;
|
||||||
enableEoscDataTransfer?:boolean;
|
enableEoscDataTransfer?:boolean;
|
||||||
|
pdfStatisticsAPIURL?: string;
|
||||||
statisticsFrameAPIURL?: string; //delete?
|
statisticsFrameAPIURL?: string; //delete?
|
||||||
statisticsFrameNewAPIURL?: string;
|
statisticsFrameNewAPIURL?: string;
|
||||||
bipFrameAPIURL?: string;
|
bipFrameAPIURL?: string;
|
||||||
|
@ -61,7 +61,6 @@ export interface EnvProperties {
|
||||||
registryUrl?: string;
|
registryUrl?: string;
|
||||||
logoutUrl?: string;
|
logoutUrl?: string;
|
||||||
userInfoUrl?: string;
|
userInfoUrl?: string;
|
||||||
clientManagementUrl?: string,
|
|
||||||
developersApiUrl?: string,
|
developersApiUrl?: string,
|
||||||
cookieDomain?: string;
|
cookieDomain?: string;
|
||||||
feedbackmail?: string;
|
feedbackmail?: string;
|
||||||
|
|
|
@ -75,6 +75,7 @@ export let common: EnvProperties = {
|
||||||
admins: ['feedback@openaire.eu'],
|
admins: ['feedback@openaire.eu'],
|
||||||
b2noteAPIURL: 'https://b2note.eudat.eu/',
|
b2noteAPIURL: 'https://b2note.eudat.eu/',
|
||||||
myOrcidLinksPage: "/my-orcid-links",
|
myOrcidLinksPage: "/my-orcid-links",
|
||||||
|
|
||||||
footerGrantText: "OpenAIRE has received funding from the European Union's Horizon 2020 research and innovation programme under grant agreements No. 777541 and 101017452",
|
footerGrantText: "OpenAIRE has received funding from the European Union's Horizon 2020 research and innovation programme under grant agreements No. 777541 and 101017452",
|
||||||
|
|
||||||
//connect
|
//connect
|
||||||
|
@ -90,6 +91,7 @@ export let common: EnvProperties = {
|
||||||
|
|
||||||
export let commonDev: EnvProperties = {
|
export let commonDev: EnvProperties = {
|
||||||
environment: "development",
|
environment: "development",
|
||||||
|
pdfStatisticsAPIURL: "https://beta.services.openaire.eu/pdf-stats",
|
||||||
statisticsAPIURL: "http://vatopedi.di.uoa.gr:8080/stats/",
|
statisticsAPIURL: "http://vatopedi.di.uoa.gr:8080/stats/",
|
||||||
statisticsFrameAPIURL: "https://beta.openaire.eu/stats/",
|
statisticsFrameAPIURL: "https://beta.openaire.eu/stats/",
|
||||||
statisticsFrameNewAPIURL: "https://stats.madgik.di.uoa.gr/stats-api/",
|
statisticsFrameNewAPIURL: "https://stats.madgik.di.uoa.gr/stats-api/",
|
||||||
|
@ -133,6 +135,7 @@ export let commonDev: EnvProperties = {
|
||||||
|
|
||||||
export let commonTest: EnvProperties = {
|
export let commonTest: EnvProperties = {
|
||||||
environment: "test",
|
environment: "test",
|
||||||
|
pdfStatisticsAPIURL: "https://services.openaire.eu/pdf-stats",
|
||||||
statisticsAPIURL: "https://beta.services.openaire.eu/stats-api/",
|
statisticsAPIURL: "https://beta.services.openaire.eu/stats-api/",
|
||||||
statisticsFrameAPIURL: "https://www.openaire.eu/stats/",
|
statisticsFrameAPIURL: "https://www.openaire.eu/stats/",
|
||||||
statisticsFrameNewAPIURL: "https://services.openaire.eu/stats-tool/",
|
statisticsFrameNewAPIURL: "https://services.openaire.eu/stats-tool/",
|
||||||
|
@ -159,11 +162,11 @@ export let commonTest: EnvProperties = {
|
||||||
baseOpenaireLink: 'https://explore.openaire.eu',
|
baseOpenaireLink: 'https://explore.openaire.eu',
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export let commonBeta: EnvProperties = {
|
export let commonBeta: EnvProperties = {
|
||||||
environment: "beta",
|
environment: "beta",
|
||||||
|
pdfStatisticsAPIURL: "https://beta.services.openaire.eu/pdf-stats",
|
||||||
statisticsAPIURL: "https://beta.services.openaire.eu/stats-api/",
|
statisticsAPIURL: "https://beta.services.openaire.eu/stats-api/",
|
||||||
statisticsFrameAPIURL: "https://beta.openaire.eu/stats/",
|
statisticsFrameAPIURL: "https://beta.openaire.eu/stats/",
|
||||||
statisticsFrameNewAPIURL: "https://beta.services.openaire.eu/stats-tool/",
|
statisticsFrameNewAPIURL: "https://beta.services.openaire.eu/stats-tool/",
|
||||||
|
@ -186,6 +189,7 @@ export let commonBeta: EnvProperties = {
|
||||||
widgetLink: "https://beta.openaire.eu/index.php?option=com_openaire&view=widget&format=raw&projectId=",
|
widgetLink: "https://beta.openaire.eu/index.php?option=com_openaire&view=widget&format=raw&projectId=",
|
||||||
claimsInformationLink: "https://beta.openaire.eu/linking",
|
claimsInformationLink: "https://beta.openaire.eu/linking",
|
||||||
indexInfoAPI: "https://beta.services.openaire.eu/openaire/info/",
|
indexInfoAPI: "https://beta.services.openaire.eu/openaire/info/",
|
||||||
|
|
||||||
adminPortalURL: "https://beta.admin.connect.openaire.eu",
|
adminPortalURL: "https://beta.admin.connect.openaire.eu",
|
||||||
baseOpenaireLink: 'https://beta.explore.openaire.eu',
|
baseOpenaireLink: 'https://beta.explore.openaire.eu',
|
||||||
|
|
||||||
|
@ -203,6 +207,7 @@ export let commonBeta: EnvProperties = {
|
||||||
|
|
||||||
export let commonProd: EnvProperties = {
|
export let commonProd: EnvProperties = {
|
||||||
environment: "production",
|
environment: "production",
|
||||||
|
pdfStatisticsAPIURL: "https://services.openaire.eu/pdf-stats",
|
||||||
statisticsAPIURL: "https://beta.services.openaire.eu/stats-api/",
|
statisticsAPIURL: "https://beta.services.openaire.eu/stats-api/",
|
||||||
statisticsFrameAPIURL: "https://www.openaire.eu/stats/",
|
statisticsFrameAPIURL: "https://www.openaire.eu/stats/",
|
||||||
statisticsFrameNewAPIURL: "https://services.openaire.eu/stats-tool/",
|
statisticsFrameNewAPIURL: "https://services.openaire.eu/stats-tool/",
|
||||||
|
@ -275,3 +280,4 @@ eoscDataTransferAPI?;
|
||||||
eoscDataTransferLoginUrl?;
|
eoscDataTransferLoginUrl?;
|
||||||
eoscDataTransferDestinations?;
|
eoscDataTransferDestinations?;
|
||||||
* */
|
* */
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue