uk-margin-top added in landing and deposit pages | icon-chart added in statistics and metrics tab (landing pages) | deposit: if no organization selected show warning message

git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-portal/trunk@45402 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
konstantina.galouni 2017-01-16 14:16:14 +00:00
parent b13689048e
commit dc5fa6506e
13 changed files with 68 additions and 41 deletions

View File

@ -8,7 +8,7 @@ import {SearchOrganizationsService} from '../services/searchOrganizations.servic
@Component({
selector: 'deposit',
template: `
<div class="container">
<div class="container uk-margin-top">
<div class="page-header" >
<h2>Deposit {{requestFor}}</h2>
</div>
@ -19,26 +19,27 @@ import {SearchOrganizationsService} from '../services/searchOrganizations.servic
Are you a grant recipient from the following: H2020; FP7 with SC39; or ERC?
</i>
Then you are required to publish in
<a href="{{openAccess}}">open access</a>.
<a href="{{openAccess}}" target="_blank">open access ( <i class="uk-icon-external-link"></i> )</a>.
One way to do this is to deposit your {{requestFor}} into an
<a href="{{openAccessRepo}}">open access repository</a>.
<a href="{{openAccessRepo}}" target="_blank">open access repository ( <i class="uk-icon-external-link"></i> )</a>.
</p>
<p>
Click the following to find more information:
<a href="{{fp7Guidlines}}">FP7 guidelines</a>,
<a href="{{h2020Guidlines}}">H2020 guidelines</a>,
<a href="{{ercGuidlines}}">ERC guidelines</a> OR
<a href="{{helpdesk}}">ask a question</a> to OpenAIREs national representative.
<a href="{{fp7Guidlines}}" target="_blank">FP7 guidelines ( <i class="uk-icon-external-link"></i> )</a>,
<a href="{{h2020Guidlines}}" target="_blank">H2020 guidelines ( <i class="uk-icon-external-link"></i> )</a>,
<a href="{{ercGuidlines}}" target="_blank">ERC guidelines ( <i class="uk-icon-external-link"></i> )</a> OR
<a href="{{helpdesk}}" target="_blank">ask a question ( <i class="uk-icon-external-link"></i> )</a> to OpenAIREs national representative.
</p>
<h3>Locate data provider via your institution</h3>
<form class= "uk-form uk-form-row">
<entities-autocomplete [entityType]="'organization'" [depositType]=compatibility [selectedValue]=selectedId [showSelected]=true
<entities-autocomplete (click)="warningMessage = ''" [entityType]="'organization'" [depositType]=compatibility [selectedValue]=selectedId [showSelected]=true
[placeHolderMessage] = "'Search for Organizations'" [title] = "'Organizations'" [multipleSelections]=false
(selectedValueChanged)="valueChanged($event)" ></entities-autocomplete>
<button class="uk-button" type="submit" (click)="organizationSelected(selectedId)" >Next</button>
(selectedValueChanged)="valueChanged($event)">
</entities-autocomplete>
<button class="uk-button" type="submit" (click)="organizationSelected(selectedId)" >Next</button>
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
</form>
</div>
</div>
@ -59,7 +60,8 @@ export class DepositComponent {
public status: number;
public errorCodes:ErrorCodes = new ErrorCodes();
public selectedId = "";
public selectedId: string = "";
private warningMessage: string = "";
constructor (private _router: Router, private _searchOrganizationsService: SearchOrganizationsService) {
@ -74,13 +76,15 @@ export class DepositComponent {
organizationSelected(id: string) {
if(id && id.length > 0){
if(this.requestFor == "Publications") {
this._router.navigate( ['deposit-publications-result'], { queryParams: { "organizationId": id } } );
} else if(this.requestFor == "Research Data") {
this._router.navigate( ['deposit-datasets-result'], { queryParams: { "organizationId": id } } );
}
console.info("organization selected");
if(id && id.length > 0){
if(this.requestFor == "Publications") {
this._router.navigate( ['deposit-publications-result'], { queryParams: { "organizationId": id } } );
} else if(this.requestFor == "Research Data") {
this._router.navigate( ['deposit-datasets-result'], { queryParams: { "organizationId": id } } );
}
} else {
this.warningMessage = "No organization selected";
}
}

View File

@ -12,7 +12,7 @@ import {OrganizationService} from '../services/organization.service';
@Component({
selector: 'deposit-result',
template: `
<div class="container">
<div class="container uk-margin-top">
<div class="page-header" >
<h2>Deposit {{requestFor}}</h2>
</div>

View File

@ -1,4 +1,4 @@
<div class="uk-container person">
<div class="uk-container uk-margin-top datasource">
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>

View File

@ -17,6 +17,9 @@ import { SearchDataprovidersService } from '../../services/searchDataproviders.s
<li *ngIf="tabs.length>0" class="uk-active">
<a href="#{{tabs[0].content}}">
{{tabs[0].name}}
<i *ngIf="tabs[0].content == 'metricsTab'" class="uk-icon-line-chart"></i>
<i *ngIf="tabs[0].content == 'statisticsTab'" class="uk-icon-pie-chart"></i>
<span class="uk-badge uk-badge-notification" *ngIf="tabs[0].content=='publicationsTab'">
{{searchPublicationsComponent.searchUtils.totalResults}}
</span>
@ -39,6 +42,9 @@ import { SearchDataprovidersService } from '../../services/searchDataproviders.s
<a *ngIf="i>0"
(click)="search(tab.content, 1, 10)" href="#{{tab.content}}">
{{tab.name}}
<i *ngIf="tab.content == 'metricsTab'" class="uk-icon-line-chart"></i>
<i *ngIf="tab.content == 'statisticsTab'" class="uk-icon-pie-chart"></i>
<span class="uk-badge uk-badge-notification" *ngIf="tab.content=='publicationsTab'">
{{searchPublicationsComponent.searchUtils.totalResults}}
</span>

View File

@ -1,4 +1,4 @@
<div class="uk-container dataset">
<div class="uk-container uk-margin-top dataset">
<!--div class="container-header" -->
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>

View File

@ -1,4 +1,4 @@
<div class="uk-container organization">
<div class="uk-container uk-margin-top organization">
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>

View File

@ -1,4 +1,4 @@
<div class="uk-container person">
<div class="uk-container uk-margin-top person">
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>

View File

@ -1,4 +1,4 @@
<div class="uk-container person">
<div class="uk-container uk-margin-top project">
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div>
@ -6,7 +6,7 @@
<div class="uk-width-7-10">
<!--h3 *ngIf="projectInfo.acronym != undefined && projectInfo.acronym != ''">{{projectInfo.acronym}}</h3>
<h3 *ngIf="projectInfo.acronym == undefined || projectInfo.acronym == ''">{{projectInfo.title}}</h3-->
<h3>{{projectName}}</h3>
<h2>{{projectName}}</h2>
<dl class="uk-description-list-horizontal custom-description-list-horizontal">
<dt *ngIf="projectInfo.title != undefined && projectInfo.title != ''">Title: </dt>
@ -75,11 +75,13 @@
<li (click)="statsClicked=true;">
<a href="#statisticsTab">
Statistics
<i class="uk-icon-pie-chart"></i>
</a>
</li>
<li (click)="metricsClicked=true;">
<a href="#metricsTab">
Metrics
<i class="uk-icon-line-chart"></i>
</a>
</li>
</ul>

View File

@ -1,4 +1,4 @@
<div class="uk-container publication">
<div class="uk-container uk-margin-top publication">
<!--div class="container-header" -->
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div>
@ -102,6 +102,7 @@
<li>
<a href="#metricsTab" (click)="metricsClicked=true;">
Metrics
<i class="uk-icon-line-chart"></i>
</a>
</li>
</ul>
@ -242,6 +243,10 @@
<dl class="uk-description-list-line functionsSection">
<dt >Share - Bookmark</dt>
<dd>
<!--div *ngIf="doi != undefined"
data-badge-popover="right" data-badge-type="donut"
data-doi="10.7717/peerj.1150" class="altmetric-embed">
</div-->
</dd>
</dl>
</li>

View File

@ -58,6 +58,8 @@ export class PublicationComponent {
public bioentitiesNum: number = 0;
private doi: string;
public result ;
/* @ViewChild (InlineClaimProjectComponent) inlineClaimProject : InlineClaimProjectComponent ;
@ -79,16 +81,20 @@ export class PublicationComponent {
// this.result = []
// this.result = {id: id, type :"dataset", source : "openaire", title: this.publicationInfo.title,url: '', result: '', accessRights: this.publicationInfo.bestlicense, embargoEndDate: ''};
let bioentitiesNum = 0;
if(this.publicationInfo.bioentities != undefined) {
this.publicationInfo.bioentities.forEach(function (value, key, map) {
bioentitiesNum += value.size;
});
}
this.bioentitiesNum = bioentitiesNum;
let bioentitiesNum = 0;
if(this.publicationInfo.bioentities != undefined) {
this.publicationInfo.bioentities.forEach(function (value, key, map) {
bioentitiesNum += value.size;
});
}
this.bioentitiesNum = bioentitiesNum;
this.result = {id: this.articleId, type :"publication", source : "openaire", title: this.publicationInfo.title,url: '', result: '', accessRights: this.publicationInfo.bestlicense, embargoEndDate: ''};
// this.result.push(result_);
this.result = {id: this.articleId, type :"publication", source : "openaire", title: this.publicationInfo.title,url: '', result: '', accessRights: this.publicationInfo.bestlicense, embargoEndDate: ''};
// this.result.push(result_);
if(this.publicationInfo.identifiers != undefined && this.publicationInfo.identifiers.has('doi')) {
this.doi = this.publicationInfo.identifiers.get('doi')[0];
}
},
err => {
console.log(err);

View File

@ -72,9 +72,7 @@ export class DataProviderService {
if(this.dataProviderInfo.tabsInTypes.datasetsTab.has(data[1].classid)) {
this.dataProviderInfo.tabs.push({"name": "Datasets", "content": "datasetsTab"});
}
if(this.dataProviderInfo.tabsInTypes.statisticsTab.has(data[1].classid)) {
this.dataProviderInfo.tabs.push({"name": "Statistics", "content": "statisticsTab"});
}
if(this.dataProviderInfo.tabsInTypes.projectsTab.has(data[1].classid)) {
this.dataProviderInfo.tabs.push({"name": "Projects", "content": "projectsTab"});
}
@ -87,6 +85,10 @@ export class DataProviderService {
this.dataProviderInfo.tabs.push({"name": "Related Data Providers", "content": "relatedDatasourcesTab"});
}
if(this.dataProviderInfo.tabsInTypes.statisticsTab.has(data[1].classid)) {
this.dataProviderInfo.tabs.push({"name": "Statistics", "content": "statisticsTab"});
}
this.dataProviderInfo.tabs.push({"name": "Metrics", "content": "metricsTab"});
if(this.dataProviderInfo.resultTypes.collectedFrom.has(data[1].classid)) {

View File

@ -42,9 +42,8 @@ export class DatasetService {
this._cache.set(key, res);
})
.map(res => this.parseDatasetInfo(res));
}
}
private handleError (error: Response) {
// in a real world app, we may send the error to some remote logging infrastructure
// instead of just logging it to the console

View File

@ -66,6 +66,9 @@
}
}
</script>
<!--script type='text/javascript' src='https://d1bxh8uas1mnw7.cloudfront.net/assets/embed.js'></script-->
<!-- End of Google sitelinks search markup-->
<style>
.custom-autocomplete .uk-nav-autocomplete > li > a:hover {