Publication journal info: add check if it is number (>0)

Navigation Bar: set uk-navbar-left width to  uk-width-1-3 (When title is big it overlaps menu items)
Add subject in advanced search fields
Add emailValidator in string utils



git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-library/trunk/ng-openaire-library/src/app@52717 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
argiro.kokogiannaki 2018-07-09 12:07:54 +00:00
parent fa10080fb0
commit c762941623
4 changed files with 13 additions and 7 deletions

View File

@ -182,9 +182,9 @@ export class PublicationService {
this.publicationInfo.journal['journal'] = data[5].content; this.publicationInfo.journal['journal'] = data[5].content;
this.publicationInfo.journal['issn'] = data[5].issn; this.publicationInfo.journal['issn'] = data[5].issn;
this.publicationInfo.journal['lissn'] = data[5].lissn; this.publicationInfo.journal['lissn'] = data[5].lissn;
this.publicationInfo.journal['volume'] = data[5].vol; this.publicationInfo.journal['volume'] = (data[5].vol>0)?data[5].vol:0;
this.publicationInfo.journal['start_page'] = data[5].sp; this.publicationInfo.journal['start_page'] = (data[5].sp > 0)?data[5].sp:null;
this.publicationInfo.journal['end_page'] = data[5].ep; this.publicationInfo.journal['end_page'] = (data[5].ep > 0)?data[5].ep:null;
} }
if(data[6] != null) { if(data[6] != null) {

View File

@ -123,7 +123,7 @@
<div [class]="'uk-navbar-container uk-sticky uk-navbar-transparent uk-light '+portal+'-menu'" uk-sticky="" media="768" cls-active="uk-active uk-navbar-sticky" animation="uk-animation-slide-top" top=".tm-header + [class*=&quot;uk-section&quot;]" cls-inactive="uk-navbar-transparent uk-light" style=""> <div [class]="'uk-navbar-container uk-sticky uk-navbar-transparent uk-light '+portal+'-menu'" uk-sticky="" media="768" cls-active="uk-active uk-navbar-sticky" animation="uk-animation-slide-top" top=".tm-header + [class*=&quot;uk-section&quot;]" cls-inactive="uk-navbar-transparent uk-light" style="">
<div class="uk-container uk-container-expand"> <div class="uk-container uk-container-expand">
<nav class="uk-navbar" uk-navbar="{&quot;align&quot;:&quot;left&quot;}"> <nav class="uk-navbar" uk-navbar="{&quot;align&quot;:&quot;left&quot;}">
<div class="uk-navbar-left uk-visible@l "> <div class="uk-navbar-left uk-visible@l uk-width-1-3">
<a routerLinkActive="uk-link" routerLink="/" class="uk-logo uk-navbar-item"> <a routerLinkActive="uk-link" routerLink="/" class="uk-logo uk-navbar-item">
<img *ngIf="!community" src="{{logoPath}}logo-large-{{portal}}.png" alt="OpenAIRE" class="uk-responsive-height"> <img *ngIf="!community" src="{{logoPath}}logo-large-{{portal}}.png" alt="OpenAIRE" class="uk-responsive-height">
@ -131,7 +131,7 @@
<div *ngIf="community" class="uk-margin-left uk-text-large"> {{community.name}} </div> <div *ngIf="community" class="uk-margin-left uk-text-large"> {{community.name}} </div>
</a> </a>
</div> </div>
<div class="uk-navbar-left uk-visible@m uk-hidden@l"> <div class="uk-navbar-left uk-visible@m uk-hidden@l uk-width-1-3">
<a routerLinkActive="uk-link" routerLink="/" class="uk-logo uk-navbar-item"> <a routerLinkActive="uk-link" routerLink="/" class="uk-logo uk-navbar-item">
<img *ngIf="!community" src="{{logoPath}}logo-small-{{portal}}.png" alt="OpenAIRE" class="uk-responsive-height"> <img *ngIf="!community" src="{{logoPath}}logo-small-{{portal}}.png" alt="OpenAIRE" class="uk-responsive-height">
<img *ngIf="community && community.logoUrl && community.logoUrl.length > 0" src="{{community.logoUrl}}" class="uk-responsive-height"> <img *ngIf="community && community.logoUrl && community.logoUrl.length > 0" src="{{community.logoUrl}}" class="uk-responsive-height">

View File

@ -10,7 +10,7 @@ export class SearchFields {
"relproject","resultacceptanceyear", "relproject","resultacceptanceyear",
"resultbestaccessright", "instancetypename", "resultlanguagename", "community","resulthostingdatasource"]; "resultbestaccessright", "instancetypename", "resultlanguagename", "community","resulthostingdatasource"];
public RESULT_ADVANCED_FIELDS:string[] = ["q","resulttitle","resultauthor","resultpublisher", public RESULT_ADVANCED_FIELDS:string[] = ["q","resulttitle","resultauthor","resultsubject","resultpublisher",
"resultbestaccessright","community","collectedfromdatasourceid","resulthostingdatasourceid", "resultdateofacceptance", "resultbestaccessright","community","collectedfromdatasourceid","resulthostingdatasourceid", "resultdateofacceptance",
"relfunder", "relfunder",
"relfundinglevel0_id","relfundinglevel1_id","relfundinglevel2_id", "relfundinglevel0_id","relfundinglevel1_id","relfundinglevel2_id",
@ -19,6 +19,7 @@ export class SearchFields {
["q"]:{name:"All fields", type:"keyword", param:"q", operator: "op", equalityOperator: "="}, ["q"]:{name:"All fields", type:"keyword", param:"q", operator: "op", equalityOperator: "="},
["resulttitle"]:{name:"Title", type:"keyword", param:"title", operator: "tt", equalityOperator: "="}, ["resulttitle"]:{name:"Title", type:"keyword", param:"title", operator: "tt", equalityOperator: "="},
["resultauthor"]:{name:"Author", type:"keyword", param:"author", operator: "at", equalityOperator: "="}, ["resultauthor"]:{name:"Author", type:"keyword", param:"author", operator: "at", equalityOperator: "="},
["resultsubject"]:{name:"Subject", type:"keyword", param:"subject", operator: "sb", equalityOperator: "="},
["resultpublisher"]:{name:"Publisher", type:"keyword", param:"publisher", operator: "pb", equalityOperator: "="}, ["resultpublisher"]:{name:"Publisher", type:"keyword", param:"publisher", operator: "pb", equalityOperator: "="},
["pid"]:{name:"PID", type:"keyword", param:"pid", operator: "pd", equalityOperator: " = "}, ["pid"]:{name:"PID", type:"keyword", param:"pid", operator: "pd", equalityOperator: " = "},
["resulthostingdatasourceid"]:{name:"Hosting Content Provider", type:"entity", param:"hostedBy", operator: "hs", equalityOperator: " exact "}, ["resulthostingdatasourceid"]:{name:"Hosting Content Provider", type:"entity", param:"hostedBy", operator: "hs", equalityOperator: " exact "},

View File

@ -124,6 +124,11 @@ export class StringUtils{
return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2); return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
}).join('')); }).join(''));
} }
private emailValidator(email : any): boolean {
if (email.match("^[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$"))
return true;
else
return false;
}
} }