+
-
-
- Share {{requestFor}}
-
+
+
+ Share {{requestFor}}
+
@@ -51,25 +52,31 @@ import {ZenodoInformationClass} from './utils/zenodoInformation.class';
-
0)">
- Please use the information below and contact your repository to deposit your {{requestFor}} .
+ Please use the information below and contact your repository to deposit your {{requestFor}} .
0)"
- class="uk-align-center uk-margin-remove-bottom">
-
+ class="uk-align-center uk-margin-remove-bottom">
+
+ class="uk-animation-fade uk-margin-top uk-width-1-1" role="alert">
-
-
+
+
-
{{result['type']}}
-
{{result.compatibility}}
+
{{result['type']}}
+
{{result.compatibility}}
-
0">
-
Organization:
-
+ 0">
+
Organization:
+
-
+
{{organization.name}}
+ *ngIf="!organization.id">
{{organization.name}} ,
+ *ngIf="(i < result['organizations'].length-1) && (i < 9)">,
-
10">...
+
10">...
0">
- Country: {{country}}{{(i < ( result['countries'].slice(0,10).length-1))?", ":""}}{{(i == result['countries'].slice(0,10).length-1 && result['countries'].length > 10)?"...":""}}
+ Country: {{country}}{{(i < (result['countries'].slice(0, 10).length - 1)) ? ", " : ""}}{{(i == result['countries'].slice(0, 10).length - 1 && result['countries'].length > 10) ? "..." : ""}}
Website URL:
-
+
{{result['websiteURL']}}
@@ -142,7 +169,7 @@ import {ZenodoInformationClass} from './utils/zenodoInformation.class';
OAI-PMH URL:
-
+
{{result['OAIPMHURL']}}
@@ -150,50 +177,52 @@ import {ZenodoInformationClass} from './utils/zenodoInformation.class';
0">
- Subject: {{subject}}{{(i < ( result['subjects'].slice(0,10).length-1))?", ":""}}{{(i == result['subjects'].slice(0,10).length-1 && result['subjects'].length > 10)?"...":""}}
+ Subject: {{subject}}{{(i < (result['subjects'].slice(0, 10).length - 1)) ? ", " : ""}}{{(i == result['subjects'].slice(0, 10).length - 1 && result['subjects'].length > 10) ? "..." : ""}}
-
- No organization with ID: {{organizationId}} found.
-
-
- An error occured.
-
-
+ status == errorCodes.NOT_AVAILABLE || status == errorCodes.NONE"
+ class="alert alert-warning">
+
+ No organization with ID: {{organizationId}} found.
+
+
+ An error occured.
+
+
Service temprorarily unavailable. Please try again later.
-
- No ID for organization.
-
+
+ No ID for organization.
+
+ && fetchDataproviders.searchUtils.status != errorCodes.LOADING" class="alert alert-warning">
An error occured.
-
+
Service temprorarily unavailable. Please try again later.
-
+
Requested page out of bounds.
-
-
- No content providers found with classification "{{subject}}" .
-
+
+
+ No content providers found with classification "{{subject}}" .
+
@@ -202,7 +231,8 @@ import {ZenodoInformationClass} from './utils/zenodoInformation.class';
Deposit your {{requestFor}} in
-
+
{{zenodoInformation.name}} ( )
More Zenodo communities
@@ -216,16 +246,20 @@ import {ZenodoInformationClass} from './utils/zenodoInformation.class';
-
- Back
+
+
+ Back
-
+
-
- `
+
+ `
})
export class DepositResultComponent {
@@ -234,208 +268,206 @@ export class DepositResultComponent {
@Input() piwikSiteId = null;
// Type of entity: Publication or Research Data
@Input() requestFor: string = "Publications";
-
- public organization: {"name": string, "url": string};
+
+ public organization: { "name": string, "url": string };
public organizationId: string = "";
-
+
// Id of the new selected organization to be searched
public selectedId: string = "";
-
+
@Input() subjectResults: boolean = false;
@Input() subject: string = "";
-
+
public status: number;
public warningMessage: string = "";
-
- public fetchDataproviders : FetchDataproviders;
+
+ public fetchDataproviders: FetchDataproviders;
public linkToSearchDataproviders: string = "";
-
- public parameterNames:string[] =[];
- public parameterValues:string[] =[];
-
- public routerHelper:RouterHelper = new RouterHelper();
- public errorCodes:ErrorCodes = new ErrorCodes();
-
- sub: any; piwiksub: any;
- properties:EnvProperties;
- url=null;
-
- constructor ( private _router: Router,
- private route: ActivatedRoute,
- private _searchDataprovidersService: SearchDataprovidersService,
- private _organizationService: OrganizationService,
- private _meta: Meta,
- private _title: Title,
- private _piwikService:PiwikService,
+
+ public parameterNames: string[] = [];
+ public parameterValues: string[] = [];
+
+ public routerHelper: RouterHelper = new RouterHelper();
+ public errorCodes: ErrorCodes = new ErrorCodes();
+ sub: any;
+ piwiksub: any;
+ properties: EnvProperties = properties;
+ url = null;
+
+ constructor(private _router: Router,
+ private route: ActivatedRoute,
+ private _searchDataprovidersService: SearchDataprovidersService,
+ private _organizationService: OrganizationService,
+ private _meta: Meta,
+ private _title: Title,
+ private _piwikService: PiwikService,
private seoService: SEOService) {
-
- this.fetchDataproviders = new FetchDataproviders(this._searchDataprovidersService);
-
- this.status = this.errorCodes.LOADING;
-
-
- var title = "Deposit "+this.requestFor;
- var description = "Openaire, repositories, open access, content provider, compatibility, organization, deposit "+ this.requestFor;
-
- this.updateTitle(title);
- this.updateDescription(description);
-
+
+ this.fetchDataproviders = new FetchDataproviders(this._searchDataprovidersService);
+
+ this.status = this.errorCodes.LOADING;
+
+
+ var title = "Deposit " + this.requestFor;
+ var description = "Openaire, repositories, open access, content provider, compatibility, organization, deposit " + this.requestFor;
+
+ this.updateTitle(title);
+ this.updateDescription(description);
+
+ }
+
+ ngOnInit() {
+ this.seoService.createLinkForCanonicalURL(this.properties.baseLink + this._router.url, false);
+ this.updateUrl(this.properties.baseLink + this._router.url);
+ this.url = this.properties.baseLink + this._router.url;
+
+ if (this.properties.enablePiwikTrack && (typeof document !== 'undefined')) {
+ this.piwiksub = this._piwikService.trackView(this.properties, "Deposit " + this.requestFor, this.piwikSiteId).subscribe();
}
- ngOnInit() {
- this.route.data
- .subscribe((data: { envSpecific: EnvProperties }) => {
- this.properties = data.envSpecific;
- this.seoService.createLinkForCanonicalURL(this.properties.baseLink+this._router.url, false);
- this.updateUrl(data.envSpecific.baseLink+this._router.url);
- this.url = data.envSpecific.baseLink+this._router.url;
-
- if(this.properties.enablePiwikTrack && (typeof document !== 'undefined')){
- this.piwiksub = this._piwikService.trackView(this.properties, "Deposit "+this.requestFor, this.piwikSiteId).subscribe();
- }
- });
-
- this.sub = this.route.queryParams.subscribe(params => {
- this.fetchDataproviders.searchUtils.page = (params['page']=== undefined)?1:+params['page'];
-
- if(this.subjectResults) {
- this.status = this.errorCodes.DONE;
-
- this.subject = params['subject'];
- if(!this.subject) {
- this.subject = "";
- }
- this.parameterNames.push('subject');
- this.parameterValues.push(this.subject);
-
- this.searchDataprovidersBySubject();
- } else {
- if(this.organizationId) {
- this.searchDataproviders();
- } else {
- this.organizationId = params['organizationId'];
- this.parameterNames.push('organizationId');
- this.parameterValues.push(this.organizationId);
-
- if(this.organizationId){
- this.getOrganizationInfo();
- }
- }
- this.selectedId = "";
- }
- });
- }
-
- ngDoCheck() {
- if(!this.subjectResults && (this.organizationId == "" || this.organizationId == undefined)) {
- this.organizationId = "";
- this.status = this.errorCodes.NONE;
- this.fetchDataproviders.searchUtils.status = this.errorCodes.NONE;
+ this.sub = this.route.queryParams.subscribe(params => {
+ this.fetchDataproviders.searchUtils.page = (params['page'] === undefined) ? 1 : +params['page'];
+
+ if (this.subjectResults) {
+ this.status = this.errorCodes.DONE;
+
+ this.subject = params['subject'];
+ if (!this.subject) {
+ this.subject = "";
}
- }
-
- ngOnDestroy() {
- this.sub.unsubscribe();
- if(this.piwiksub){
- this.piwiksub.unsubscribe();
- }
- }
-
- public newSubject() {
- this._router.navigate( ['participate/deposit-subject-result'], { queryParams: { "subject": this.subject } } );
- }
-
- public searchDataprovidersBySubject() {
- this.parameterNames = [];
- this.parameterValues = [];
this.parameterNames.push('subject');
this.parameterValues.push(this.subject);
-
- this.fetchDataproviders.getResultsBySubjectsForDeposit( (this.subject =="")?"*":this.subject, this.requestFor, this.fetchDataproviders.searchUtils.page, this.fetchDataproviders.searchUtils.size, this.properties);
- this.linkToSearchDataproviders = this.properties.searchLinkToDataProviders;
- }
-
- private searchDataproviders() {
- // if(this.organization != undefined) {
- // this.fetchDataproviders.getResults(this.organization.name, false, 1, 10);
- // } else if(this.organizationId != undefined) {
- this.fetchDataproviders.getResultsForDeposit( this.organizationId,this.requestFor, this.fetchDataproviders.searchUtils.page, this.fetchDataproviders.searchUtils.size, this.properties);
- //}
- this.linkToSearchDataproviders = this.properties.searchLinkToDataProviders;
- }
-
- private getOrganizationInfo () {
- this.fetchDataproviders.oldTotalResults = 0;
- this.fetchDataproviders.searchUtils.totalResults = 0;
-
- this._organizationService.getOrganizationNameAndUrlById(this.organizationId,this.properties).subscribe(
- data => {
- if(data == null) {
- this.status = this.errorCodes.NOT_FOUND;
- this.fetchDataproviders.searchUtils.status = this.errorCodes.NONE;
- } else {
- this.organization = data;
- this.status = this.errorCodes.DONE;
- this.searchDataproviders();
- }
- },
- err => {
- //console.log(err)
- this.handleError("Error getting organization name and url for id: "+this.organizationId, err);
-
- this.fetchDataproviders.searchUtils.status = this.errorCodes.NONE;
- if(err.status == '404') {
- this.status = this.errorCodes.NOT_FOUND;
- } else if(err.status == '500') {
- this.status = this.errorCodes.ERROR;
- } else {
- this.status = this.errorCodes.NOT_AVAILABLE;
- }
- }
- );
- }
-
- public goToDeposit() {
- if(this.requestFor == "Publications") {
- this._router.navigate( ['participate/deposit-publications'] );
- } else if(this.requestFor == "Research Data") {
- this._router.navigate( ['participate/deposit-datasets'] );
- }
- }
-
- public valueChanged($event){
- this.selectedId = $event.value;
- }
-
- public organizationSelected(id: string) {
- if(id && id.length > 0 && id != this.organizationId){
- this.organization = null;
- this.status = this.errorCodes.LOADING;
-
- if(this.requestFor == "Publications") {
- this._router.navigate( ['participate/deposit-publications-result'], { queryParams: { "organizationId": id } } );
- } else if(this.requestFor == "Research Data") {
- this._router.navigate( ['participate/deposit-datasets-result'], { queryParams: { "organizationId": id } } );
- }
+
+ this.searchDataprovidersBySubject();
+ } else {
+ if (this.organizationId) {
+ this.searchDataproviders();
} else {
- this.warningMessage = "No new organization selected";
+ this.organizationId = params['organizationId'];
+ this.parameterNames.push('organizationId');
+ this.parameterValues.push(this.organizationId);
+
+ if (this.organizationId) {
+ this.getOrganizationInfo();
+ }
}
+ this.selectedId = "";
+ }
+ });
+ }
+
+ ngDoCheck() {
+ if (!this.subjectResults && (this.organizationId == "" || this.organizationId == undefined)) {
+ this.organizationId = "";
+ this.status = this.errorCodes.NONE;
+ this.fetchDataproviders.searchUtils.status = this.errorCodes.NONE;
}
-
- private updateDescription(description:string) {
- this._meta.updateTag({content:description},"name='description'");
- this._meta.updateTag({content:description},"property='og:description'");
+ }
+
+ ngOnDestroy() {
+ this.sub.unsubscribe();
+ if (this.piwiksub) {
+ this.piwiksub.unsubscribe();
}
- private updateTitle(title:string){
- var _prefix ="OpenAIRE | ";
- var _title = _prefix + ((title.length> 50 ) ?title.substring(0,50):title);
- this._title.setTitle(_title);
- this._meta.updateTag({content:_title},"property='og:title'");
+ }
+
+ public newSubject() {
+ this._router.navigate(['participate/deposit-subject-result'], {queryParams: {"subject": this.subject}});
+ }
+
+ public searchDataprovidersBySubject() {
+ this.parameterNames = [];
+ this.parameterValues = [];
+ this.parameterNames.push('subject');
+ this.parameterValues.push(this.subject);
+
+ this.fetchDataproviders.getResultsBySubjectsForDeposit((this.subject == "") ? "*" : this.subject, this.requestFor, this.fetchDataproviders.searchUtils.page, this.fetchDataproviders.searchUtils.size, this.properties);
+ this.linkToSearchDataproviders = this.properties.searchLinkToDataProviders;
+ }
+
+ private searchDataproviders() {
+ // if(this.organization != undefined) {
+ // this.fetchDataproviders.getResults(this.organization.name, false, 1, 10);
+ // } else if(this.organizationId != undefined) {
+ this.fetchDataproviders.getResultsForDeposit(this.organizationId, this.requestFor, this.fetchDataproviders.searchUtils.page, this.fetchDataproviders.searchUtils.size, this.properties);
+ //}
+ this.linkToSearchDataproviders = this.properties.searchLinkToDataProviders;
+ }
+
+ private getOrganizationInfo() {
+ this.fetchDataproviders.oldTotalResults = 0;
+ this.fetchDataproviders.searchUtils.totalResults = 0;
+
+ this._organizationService.getOrganizationNameAndUrlById(this.organizationId, this.properties).subscribe(
+ data => {
+ if (data == null) {
+ this.status = this.errorCodes.NOT_FOUND;
+ this.fetchDataproviders.searchUtils.status = this.errorCodes.NONE;
+ } else {
+ this.organization = data;
+ this.status = this.errorCodes.DONE;
+ this.searchDataproviders();
+ }
+ },
+ err => {
+ //console.log(err)
+ this.handleError("Error getting organization name and url for id: " + this.organizationId, err);
+
+ this.fetchDataproviders.searchUtils.status = this.errorCodes.NONE;
+ if (err.status == '404') {
+ this.status = this.errorCodes.NOT_FOUND;
+ } else if (err.status == '500') {
+ this.status = this.errorCodes.ERROR;
+ } else {
+ this.status = this.errorCodes.NOT_AVAILABLE;
+ }
+ }
+ );
+ }
+
+ public goToDeposit() {
+ if (this.requestFor == "Publications") {
+ this._router.navigate(['participate/deposit-publications']);
+ } else if (this.requestFor == "Research Data") {
+ this._router.navigate(['participate/deposit-datasets']);
}
- private updateUrl(url:string){
- this._meta.updateTag({content:url},"property='og:url'");
- }
-
- private handleError(message: string, error) {
- console.error("Deposit Result Page: "+message, error);
+ }
+
+ public valueChanged($event) {
+ this.selectedId = $event.value;
+ }
+
+ public organizationSelected(id: string) {
+ if (id && id.length > 0 && id != this.organizationId) {
+ this.organization = null;
+ this.status = this.errorCodes.LOADING;
+
+ if (this.requestFor == "Publications") {
+ this._router.navigate(['participate/deposit-publications-result'], {queryParams: {"organizationId": id}});
+ } else if (this.requestFor == "Research Data") {
+ this._router.navigate(['participate/deposit-datasets-result'], {queryParams: {"organizationId": id}});
+ }
+ } else {
+ this.warningMessage = "No new organization selected";
}
+ }
+
+ private updateDescription(description: string) {
+ this._meta.updateTag({content: description}, "name='description'");
+ this._meta.updateTag({content: description}, "property='og:description'");
+ }
+
+ private updateTitle(title: string) {
+ var _prefix = "OpenAIRE | ";
+ var _title = _prefix + ((title.length > 50) ? title.substring(0, 50) : title);
+ this._title.setTitle(_title);
+ this._meta.updateTag({content: _title}, "property='og:title'");
+ }
+
+ private updateUrl(url: string) {
+ this._meta.updateTag({content: url}, "property='og:url'");
+ }
+
+ private handleError(message: string, error) {
+ console.error("Deposit Result Page: " + message, error);
+ }
}
diff --git a/deposit/searchResultsInDeposit.component.html b/deposit/searchResultsInDeposit.component.html
index 0aa7814b..e8f47251 100644
--- a/deposit/searchResultsInDeposit.component.html
+++ b/deposit/searchResultsInDeposit.component.html
@@ -16,7 +16,6 @@
Deposit in Zenodo
diff --git a/landingPages/dataProvider/dataProvider.component.html b/landingPages/dataProvider/dataProvider.component.html
index ffb06c1d..ff429ea3 100644
--- a/landingPages/dataProvider/dataProvider.component.html
+++ b/landingPages/dataProvider/dataProvider.component.html
@@ -41,7 +41,7 @@
title="Compatibility">