Revision 61003
Added by Konstantina Galouni almost 3 years ago
modules/uoa-services-library/trunk/ng-openaire-library/src/app/landingPages/dataProvider/dataProvider.component.ts | ||
---|---|---|
271 | 271 |
this.subscriptions.push(this._dataproviderService.getDataproviderAggregationStatus(originalId, this.properties).subscribe( |
272 | 272 |
data => { |
273 | 273 |
this.dataProviderInfo.aggregationStatus = data; |
274 |
this.aggregationStatusIsInitialized = true; |
|
274 | 275 |
}, |
275 | 276 |
err => { |
276 | 277 |
//console.log(err); |
278 |
this.aggregationStatusIsInitialized = true; |
|
277 | 279 |
this.handleError("Error getting content provider aggregation status for id: " + this.datasourceId, err); |
278 |
}, |
|
279 |
() => { |
|
280 |
this.aggregationStatusIsInitialized = true; |
|
281 | 280 |
} |
282 | 281 |
)); |
283 | 282 |
} |
modules/uoa-services-library/trunk/ng-openaire-library/src/app/landingPages/landing-utils/showPublisher.component.ts | ||
---|---|---|
8 | 8 |
|| journal['volume'] || journal['eissn'] || journal['issue'])"> |
9 | 9 |
<span *ngIf="publishDate" class="uk-margin-right"> |
10 | 10 |
<span class="uk-text-muted">Published: </span> |
11 |
{{publishDate | date: 'dd MMM yyyy'}} |
|
11 |
{{publishDate | date: 'dd MMM yyyy' : 'UTC'}}
|
|
12 | 12 |
</span> |
13 | 13 |
<span *ngIf="journal && (journal['journal'] || journal['issn'] || journal['lissn'] |
14 | 14 |
|| journal['volume'] || journal['eissn'] || journal['issue'])"> |
modules/uoa-services-library/trunk/ng-openaire-library/src/app/landingPages/landing-utils/parsingFunctions.class.ts | ||
---|---|---|
21 | 21 |
let fundedByProject: Project = { |
22 | 22 |
"id": "", "acronym": "", "title": "", |
23 | 23 |
"funderShortname": "", "funderName": "", |
24 |
"funding": "", "code": "", "provenanceAction": "" |
|
24 |
"funding": "", "code": "", "provenanceAction": "", "validated": false
|
|
25 | 25 |
}; |
26 | 26 |
|
27 | 27 |
if (relation.title != 'unidentified') { |
... | ... | |
29 | 29 |
fundedByProject['acronym'] = relation.acronym; |
30 | 30 |
fundedByProject['title'] = relation.title; |
31 | 31 |
fundedByProject['code'] = relation.code; |
32 |
|
|
32 |
if(relation.validated && relation.validated.date) { |
|
33 |
fundedByProject['validated'] = true; |
|
34 |
} |
|
35 |
|
|
33 | 36 |
if (provenanceActionVocabulary != null && relation.provenanceaction in provenanceActionVocabulary) { |
34 | 37 |
fundedByProject['provenanceAction'] = provenanceActionVocabulary[relation.provenanceaction]; |
35 | 38 |
} |
modules/uoa-services-library/trunk/ng-openaire-library/src/app/landingPages/landing-utils/fundedBy.component.ts | ||
---|---|---|
47 | 47 |
<span class="uk-text-muted">Funding stream: </span>{{item.funding}} |
48 | 48 |
</li> |
49 | 49 |
</ul> |
50 |
<div *ngIf="item.provenanceAction" class="uk-text-muted"> |
|
51 |
{{item.provenanceAction}} |
|
50 |
<div *ngIf="item.provenanceAction || item.validated" class="uk-text-muted"> |
|
51 |
<span *ngIf="item.validated">Validated by funder</span> |
|
52 |
<span *ngIf="item.provenanceAction && item.validated"> | </span> |
|
53 |
<span *ngIf="item.provenanceAction">{{item.provenanceAction}}</span> |
|
52 | 54 |
</div> |
53 | 55 |
</div> |
54 | 56 |
<span *ngIf="i < (fundedByProjects.slice(0, showNum).length - 1)">, </span> |
modules/uoa-services-library/trunk/ng-openaire-library/src/app/orcid/orcid.component.ts | ||
---|---|---|
105 | 105 |
} |
106 | 106 |
// this.message = "Thank you for connecting your ORCID iD with OpenAIRE! Please close this window and continue!"; |
107 | 107 |
} |
108 |
this.showLoading = false; |
|
108 | 109 |
}, |
109 | 110 |
error => { |
111 |
this.showLoading = false; |
|
112 |
|
|
110 | 113 |
this.gotToken = true; |
111 | 114 |
|
112 | 115 |
console.error("Error getting token from code: "+code, error); |
113 | 116 |
this.message = "An error occured while trying to connect your ORCID iD with OpenAIRE. Please try again!"; |
114 |
}, |
|
115 |
() => { |
|
116 |
this.showLoading = false; |
|
117 | 117 |
} |
118 | 118 |
) |
119 | 119 |
} |
... | ... | |
147 | 147 |
} else { |
148 | 148 |
this._router.navigate([properties.searchLinkToAdvancedResults], {}); |
149 | 149 |
} |
150 |
}, |
|
151 |
error => { |
|
152 |
setTimeout(() => { |
|
153 |
this.message += "<div class='uk-margin-top'>If you are not authomatically redirected, please navigate to our search pages.</div>"; |
|
154 |
}, 3000); |
|
150 | 155 |
})); |
151 | 156 |
} else { |
152 | 157 |
this.getToken(this.code); |
153 | 158 |
} |
154 |
}, |
|
155 |
() => { |
|
156 |
if(this.gotToken) { |
|
157 |
setTimeout(() => { |
|
158 |
this.message += "<div class='uk-margin-top'>If you are not authomatically redirected, please navigate to our search pages.</div>"; |
|
159 |
}, 3000); |
|
160 |
} |
|
161 | 159 |
} |
162 | 160 |
)); |
163 | 161 |
} |
... | ... | |
175 | 173 |
private updateUrl(url: string) { |
176 | 174 |
this._meta.updateTag({content: url}, "property='og:url'"); |
177 | 175 |
} |
178 |
} |
|
176 |
} |
modules/uoa-services-library/trunk/ng-openaire-library/src/app/utils/result-preview/result-preview.ts | ||
---|---|---|
42 | 42 |
funderName: string; |
43 | 43 |
funding?: string; |
44 | 44 |
code: string; |
45 |
validated?: boolean; |
|
45 | 46 |
budget?: string; |
46 | 47 |
contribution?: string; |
47 | 48 |
currency?: string; |
modules/uoa-services-library/trunk/ng-openaire-library/src/app/timeout-interceptor.service.ts | ||
---|---|---|
11 | 11 |
} |
12 | 12 |
|
13 | 13 |
intercept(req: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>> { |
14 |
if (req.method !== 'GET') { |
|
15 |
return next.handle(req); |
|
16 |
} |
|
17 |
|
|
14 | 18 |
const timeoutValue = req.headers.get('timeout') || this.defaultTimeout; |
15 | 19 |
const timeoutValueNumeric = Number(timeoutValue); |
16 | 20 |
|
Also available in: Unified diff
[Trunk | Library]:
1. result-preview.ts: In Project interface, added optional boolean field "validated" (parsed in landing pages to show validated projects by funders).
2. parsingFunctions.class.ts: In method "parseFundingByProjects()" added parsing for "validated" field.
3. fundedBy.component.ts: ticket #6228 - Show "Validated by funder" message if "validate" field is true.
4. dataProvider.component.ts: [Bug fix] In method "getDataProviderAggregationStatus()" set "aggregationStatusIsInitialized" to true on success and on error
(not on complete, because after error it never completes and keeps on loading).
5. orcid.component.ts: [Bug fix]
a. In method "getToken()" set "showLoading" to false on success and on error (after error there is no complete).
b. In method "getPersonalDetails()" move "setTimeout" from complete to error.
6. showPublisher.component.ts: [Bug fix] Add "UTC" in pipe when showing published date ({{publishDate | date: 'dd MMM yyyy' : 'UTC'}}).
7. timeout-interceptor.service.ts: Timeout only GET requests.