linking updates
This commit is contained in:
parent
dcffb611a2
commit
c9ed6a255b
|
@ -118,6 +118,11 @@
|
|||
</ng-container>
|
||||
</div>
|
||||
<div class="uk-width-expand@m uk-width-1-1@s uk-first-column">
|
||||
|
||||
<div *ngIf="openaireResultsStatus == errorCodes.LOADING" class="uk-animation-fade uk-margin-top uk-width-1-1"
|
||||
role="alert"><span class="loading-gif uk-align-center"></span></div>
|
||||
<claim-results [localStoragePrefix]="localStoragePrefix" [results]=openaireResults
|
||||
[selectedResults]=selectedProjects [basketLimit]="basketLimit"></claim-results>
|
||||
<div *ngIf="openaireResultsNum != null && openaireResultsNum > 0" class="uk-clearfix ">
|
||||
<div class= "paging-hr searchPaging uk-margin-small-bottom"
|
||||
*ngIf="(openaireResultsNum > 0) || (openaireResultsStatus == errorCodes.LOADING)">
|
||||
|
@ -138,10 +143,6 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div *ngIf="openaireResultsStatus == errorCodes.LOADING" class="uk-animation-fade uk-margin-top uk-width-1-1"
|
||||
role="alert"><span class="loading-gif uk-align-center"></span></div>
|
||||
<claim-results [localStoragePrefix]="localStoragePrefix" [results]=openaireResults
|
||||
[selectedResults]=selectedProjects [basketLimit]="basketLimit"></claim-results>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -59,7 +59,7 @@
|
|||
class="portal-color">{{countTotalPages(crossrefResultsNum)|number}}</span>
|
||||
|
||||
</div>-->
|
||||
<div class="uk-width-1-1@s uk-width-1-2@m uk-text-uppercase"
|
||||
<!-- <div class="uk-width-1-1@s uk-width-1-2@m uk-text-uppercase"
|
||||
*ngIf="crossrefResultsNum > 0">
|
||||
{{crossrefResultsNum|number}}
|
||||
<span class="uk-text-muted uk-text-uppercase"> research outcomes, page </span>
|
||||
|
@ -71,7 +71,7 @@
|
|||
<paging-no-load class="uk-float-right" [currentPage]="crossrefPage" [totalResults]="crossrefResultsNum"
|
||||
[term]="keyword"
|
||||
[size]="size" (pageChange)="crossrefPageChange($event)"></paging-no-load>
|
||||
</div>
|
||||
</div>-->
|
||||
</div>
|
||||
</div>
|
||||
<div *ngIf="crossrefStatus === errorCodes.LOADING" class="uk-animation-fade uk-margin-top uk-width-1-1"
|
||||
|
@ -81,6 +81,10 @@
|
|||
<claim-results [localStoragePrefix]=localStoragePrefix [results]=crossrefResults
|
||||
[selectedResults]=selectedResults [basketLimit]="basketLimit"></claim-results>
|
||||
</div>
|
||||
<paging-no-load *ngIf="crossrefStatus != errorCodes.LOADING && crossrefResultsNum>0 " class="uk-float-right"
|
||||
[currentPage]="crossrefPage" [totalResults]="crossrefResultsNum"
|
||||
[term]="keyword"
|
||||
[size]="size" (pageChange)="crossrefPageChange($event)"></paging-no-load>
|
||||
</div>
|
||||
</div>
|
||||
<div *ngIf="activeTab == 'openaire'" id="openaire" class="uk-animation-fade">
|
||||
|
@ -204,30 +208,7 @@
|
|||
<div *ngIf="orcidStatus == errorCodes.NONE && orcidResultsNum == -1"
|
||||
class="uk-alert uk-alert-primary "> No results found
|
||||
</div>
|
||||
<div *ngIf=" ((orcidResultsNum >0) && (totalPages > 1) && ( 0 < page && page <= totalPages )) "
|
||||
class="uk-clearfix">
|
||||
<div class="uk-grid">
|
||||
<!--<div *ngIf="orcidResultsNum>0" class="uk-width-1-2">
|
||||
<span class="portal-color">{{orcidResultsNum|number}}</span> research outcomes, page <span
|
||||
class="portal-color">{{orcidPage | number}}</span> of <span
|
||||
class="portal-color">{{countTotalPages(orcidResultsNum)|number}}</span>
|
||||
|
||||
</div>-->
|
||||
<div class="uk-width-1-1@s uk-width-1-2@m uk-text-uppercase"
|
||||
*ngIf="orcidResultsNum > 0">
|
||||
{{orcidResultsNum|number}}
|
||||
<span class="uk-text-muted uk-text-uppercase"> research outcomes, page </span>
|
||||
{{orcidPage | number}}
|
||||
<span class="uk-text-muted uk-text-uppercase"> of </span>
|
||||
{{(countTotalPages(orcidResultsNum)|number)}}
|
||||
</div>
|
||||
<div class="uk-width-1-2 uk-padding-remove-left">
|
||||
<paging-no-load class="uk-float-right" [currentPage]="orcidPage" [totalResults]="orcidResultsNum"
|
||||
[term]="keyword" [size]="size"
|
||||
(pageChange)="orcidPageChange($event)"></paging-no-load>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div *ngIf="orcidResultsNum >= 0" class="panel-body">
|
||||
<span><span class="uk-text-bold">Showing results for</span>
|
||||
<a target="_blank" href="http://orcid.org/{{authorId}}"> <span
|
||||
|
@ -257,6 +238,15 @@
|
|||
[selectedResults]=selectedResults [basketLimit]="basketLimit"></claim-results>
|
||||
<div *ngIf="orcidResultsNum == 0" class="uk-alert uk-alert-primary uk-margin-top"> No results found</div>
|
||||
</div>
|
||||
<div *ngIf=" ((orcidResultsNum >0) && (totalPages > 1) && ( 0 < page && page <= totalPages )) "
|
||||
class="uk-clearfix">
|
||||
|
||||
<paging-no-load class="uk-float-right" [currentPage]="orcidPage" [totalResults]="orcidResultsNum"
|
||||
[term]="keyword" [size]="size"
|
||||
(pageChange)="orcidPageChange($event)"></paging-no-load>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div *ngIf="orcidStatus == errorCodes.LOADING" class="uk-animation-fade uk-margin-top uk-width-1-1" role="alert">
|
||||
<span class="loading-gif uk-align-center"></span></div>
|
||||
|
@ -270,35 +260,18 @@
|
|||
role="alert">Service not available
|
||||
</div>
|
||||
<div class="uk-margin-top">
|
||||
<div *ngIf="dataciteResultsNum != null && dataciteResultsNum > 0" class="uk-clearfix ">
|
||||
<div class="uk-grid">
|
||||
<!-- <div *ngIf="dataciteResultsNum>0" class="uk-width-1-2">
|
||||
<span class="portal-color">{{dataciteResultsNum|number}}</span> research outcomes, page <span
|
||||
class="portal-color">{{datacitePage | number}}</span> of <span
|
||||
class="portal-color">{{countTotalPages(dataciteResultsNum)|number}}</span>
|
||||
|
||||
</div>-->
|
||||
<div class="uk-width-1-1@s uk-width-1-2@m uk-text-uppercase"
|
||||
*ngIf="dataciteResultsNum > 0">
|
||||
{{dataciteResultsNum|number}}
|
||||
<span class="uk-text-muted uk-text-uppercase"> research outcomes, page </span>
|
||||
{{datacitePage | number}}
|
||||
<span class="uk-text-muted uk-text-uppercase"> of </span>
|
||||
{{(countTotalPages(dataciteResultsNum)|number)}}
|
||||
</div>
|
||||
<div class="uk-width-1-2 uk-padding-remove-left">
|
||||
<paging-no-load class="uk-float-right" [currentPage]="datacitePage" [totalResults]="dataciteResultsNum"
|
||||
[term]="keyword"
|
||||
[size]="size" (pageChange)="datacitePageChange($event)"></paging-no-load>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div *ngIf="dataciteStatus == errorCodes.LOADING" class="uk-animation-fade uk-margin-top uk-width-1-1"
|
||||
role="alert"><span class="loading-gif uk-align-center"></span></div>
|
||||
<div>
|
||||
<claim-results [localStoragePrefix]=localStoragePrefix *ngIf="dataciteResults.length > 0 "
|
||||
[results]=dataciteResults [selectedResults]=selectedResults [basketLimit]="basketLimit"></claim-results>
|
||||
</div>
|
||||
<div *ngIf="dataciteResultsNum != null && dataciteResultsNum > 0" class="uk-clearfix ">
|
||||
<paging-no-load class="uk-float-right" [currentPage]="datacitePage" [totalResults]="dataciteResultsNum"
|
||||
[term]="keyword"
|
||||
[size]="size" (pageChange)="datacitePageChange($event)"></paging-no-load>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -37,14 +37,12 @@ import {Subscriber} from "rxjs";
|
|||
<div class="uk-clearfix">
|
||||
|
||||
<div>
|
||||
<div *ngIf="!claiming " (click)="insert()" style="width: 350px;"
|
||||
<a *ngIf="!claiming " (click)="insert()"
|
||||
[class]="getButtonClass()">CONFIRM LINKING
|
||||
<span [class]="(defaultColors?'':' uk-margin-small-top ')+'uk-icon uk-float-right uk-text-bold uk-margin-small-right'">
|
||||
<svg width="30" height="30" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"
|
||||
icon="chevron-right" ratio="1.5"><polyline fill="none" stroke="#000" stroke-width="1.03"
|
||||
points="7 4 13 10 7 16"></polyline></svg>
|
||||
<span [class]="(defaultColors?'':' uk-margin-small-top ')+'uk-icon uk-text-bold uk-margin-small-right'" uk-icon="arrow-right">
|
||||
|
||||
</span>
|
||||
</div>
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
@ -524,9 +522,7 @@ export class ClaimInsertComponent {
|
|||
}
|
||||
if(this.defaultColors){
|
||||
buttonClass+=" linksbaskettitles uk-padding-small ";
|
||||
}else{
|
||||
buttonClass+=" uk-button uk-button-large ";
|
||||
}
|
||||
}
|
||||
return buttonClass + "uk-text-center ";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,24 +1,39 @@
|
|||
<breadcrumbs [breadcrumbs]="breadcrumbs"></breadcrumbs>
|
||||
<div class="" >
|
||||
<div class=" uk-grid uk-child-width-1-3">
|
||||
<div>
|
||||
<div>Find Sources</div>
|
||||
<a class="uk-icon-button uk-border-circle" [class.uk-button-primary]="showOptions.show !='source'"
|
||||
[class.uk-button-secondary]="showOptions.show =='source'">1</a>
|
||||
<div class=" uk-flex uk-flex-center uk-text-small" >
|
||||
<div class=" uk-grid uk-flex uk-flex-center uk-flex-middle uk-width-auto">
|
||||
<div class=" uk-width-auto">
|
||||
|
||||
<a class="uk-icon-button uk-border-circle" [class.uk-button-primary]="showOptions.show !='source'"
|
||||
[class.uk-button-secondary]="showOptions.show =='source'" (click)="showOptions.show = 'source';
|
||||
scrollUp();">
|
||||
<span *ngIf="showOptions.show == 'source' || sources.length == 0 ">1</span>
|
||||
<span *ngIf="showOptions.show != 'source' && sources.length > 0 " uk-icon="check"></span>
|
||||
</a>
|
||||
<span class="uk-margin-small-left">Find Sources</span>
|
||||
|
||||
</div>
|
||||
<div class="mat-stepper-horizontal-line uk-margin-small-left"></div>
|
||||
<div class=" uk-width-auto">
|
||||
<a class=" uk-icon-button " [class.uk-button-primary]="showOptions.show =='claim'"
|
||||
[class.uk-button-secondary]="showOptions.show !='claim'" [class.uk-disabled]="sources.length == 0"
|
||||
(click)="openSelectionModal();">
|
||||
<span *ngIf="(showOptions.show != 'source' && showOptions.show != 'claim') || results.length == 0 ">2</span>
|
||||
<span *ngIf="!(showOptions.show != 'source' && showOptions.show != 'claim') && results.length > 0 " uk-icon="check"></span>
|
||||
|
||||
</a>
|
||||
<span class="uk-margin-small-left">Link Sources to Entities</span>
|
||||
</div>
|
||||
<div class="mat-stepper-horizontal-line uk-margin-small-left"></div>
|
||||
<div class=" uk-width-auto">
|
||||
<a class="uk-icon-button uk-border-circle" [class.uk-disabled]="sources.length == 0 || results.length == 0 "
|
||||
[class.uk-button-secondary]="showOptions.show =='claim'" (click)="showOptions.show = 'claim'; scrollUp();">3</a>
|
||||
<span class="uk-margin-small-left">Summarize and finish</span>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div>Link Sources to Entities</div>
|
||||
<a class=" uk-icon-button " [class.uk-button-primary]="showOptions.show =='claim'"
|
||||
[class.uk-button-secondary]="showOptions.show =='link'">2</a>
|
||||
</div>
|
||||
<div><div>Summarize and finish</div>
|
||||
<a class="uk-icon-button uk-border-circle"
|
||||
[class.uk-button-secondary]="showOptions.show =='claim'">3</a>
|
||||
</div>
|
||||
<progress class="uk-progress" value="0" max="100"></progress>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<metadata-preview *ngIf="showOptions.show=='claim' && properties" class="uk-margin-top"
|
||||
[results]="results" [sources]="sources"
|
||||
[localStoragePrefix]="localStoragePrefix" [inlineEntity]="inlineEntity"
|
||||
|
@ -48,7 +63,7 @@
|
|||
<div class="uk-width-2-3">
|
||||
<div class="uk-margin-small-bottom">
|
||||
|
||||
<span *ngIf="showOptions.show!='source' && showOptions.show != 'claim' && showOptions.linkToEntities.length > 1"
|
||||
<!--<span *ngIf="showOptions.show!='source' && showOptions.show != 'claim' && showOptions.linkToEntities.length > 1"
|
||||
class="uk-flex-inline uk-flex-middle uk-width-3-5@m uk-width-1-1@s">
|
||||
<span class="uk-width-1-4 uk-text-muted uk-text-large">LINK TO </span>
|
||||
<mat-select [(ngModel)]="showOptions.show" class="uk-width-3-4@m matSelection"
|
||||
|
@ -62,9 +77,9 @@
|
|||
<mat-option *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " value="context">COMMUNITIES
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
</span>
|
||||
</span>-->
|
||||
|
||||
<span *ngIf="showOptions.show!='source' && showOptions.show != 'claim' && showOptions.linkToEntities.length ==1">
|
||||
<!--<span *ngIf="showOptions.show!='source' && showOptions.show != 'claim' && showOptions.linkToEntities.length ==1">
|
||||
<span>LINK TO </span>
|
||||
<span class=" uk-width-auto uk-text-bold">
|
||||
<span *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 "
|
||||
|
@ -74,7 +89,7 @@
|
|||
<span *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 " value="context">COMMUNITIES
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</span>-->
|
||||
<!--<span *ngIf="showOptions.show=='source'" class="uk-text-bold">
|
||||
ADD LINKING SOURCES
|
||||
</span>-->
|
||||
|
@ -292,7 +307,7 @@
|
|||
<div *ngIf="showOptions.show!='source'"
|
||||
[class]="((results.length)>0?'linksbaskettitlesPortalColor ':'uk-disabled')+ ' linksbaskettitles uk-margin-small-top uk-padding-small'"
|
||||
style="height:auto !important; " (click)="showOptions.show = 'claim'; scrollUp();">
|
||||
|
||||
|
||||
<div class="uk-margin-remove portal-color uk-text-center">
|
||||
FINISH LINKING
|
||||
<span class="uk-icon uk-float-right uk-text-bold uk-margin-small-right">
|
||||
|
@ -323,7 +338,8 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<modal-alert (alertOutput)="closeSelectionModal($event)" >
|
||||
<div class="uk-grid uk-text-center uk-margin-expand uk-padding uk-child-width-1-3">
|
||||
|
||||
|
|
|
@ -17,7 +17,22 @@ declare var UIkit:any;
|
|||
|
||||
@Component({
|
||||
selector: 'linking-generic',
|
||||
templateUrl: 'linkingGeneric.component.html'
|
||||
templateUrl: 'linkingGeneric.component.html',
|
||||
styles:[ `
|
||||
.mat-stepper-horizontal-line {
|
||||
border-top-width: 1px;
|
||||
border-top-style: solid;
|
||||
flex: auto;
|
||||
height: 0;
|
||||
margin: 0 -16px;
|
||||
margin-left: -16px;
|
||||
min-width: 32px;
|
||||
}
|
||||
.mat-horizontal-stepper-header::before, .mat-horizontal-stepper-header::after, .mat-stepper-horizontal-line {
|
||||
border-top-color: rgba(0, 0, 0, 0.12);
|
||||
}
|
||||
|
||||
`]
|
||||
|
||||
})
|
||||
export class LinkingGenericComponent {
|
||||
|
|
|
@ -1,34 +1,4 @@
|
|||
<div class="uk-section uk-padding-remove-top uk-padding-remove-bottom ">
|
||||
<div
|
||||
[class]="((defaultColors)?'linkingToolbar':'communityPanelBackground')+' uk-padding-small'">
|
||||
<div class="uk-container uk-container-large uk-margin-small-top uk-padding-small">
|
||||
<div class="uk-grid">
|
||||
<div class="uk-padding-remove-left uk-margin-auto-vertical back uk-link">
|
||||
<span
|
||||
(click)="showOptions.showLinkTo()"
|
||||
style="cursor:pointer">
|
||||
<span class="uk-icon">
|
||||
<svg width="30" height="30" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="chevron-left"
|
||||
ratio="1.5"><polyline fill="none" stroke="#000" stroke-width="1.03"
|
||||
points="13 16 7 10 13 4"></polyline></svg></span>
|
||||
BACK
|
||||
</span>
|
||||
</div>
|
||||
<div class="uk-width-expand">
|
||||
<h6 class="uk-text-bold">
|
||||
LINKING CONFIRMATION
|
||||
</h6>
|
||||
Confirm that the links you provided are all correct
|
||||
</div>
|
||||
<claim-insert [results]="results" [sources]="sources" [inlineEntity]="inlineEntity"
|
||||
[properties]=properties [localStoragePrefix]=localStoragePrefix
|
||||
class=" " [errors]="errors" (insertFinished)="runValidation(false); updateLocalStorage();"
|
||||
[defaultColors]="defaultColors" [communityId]="communityId">
|
||||
</claim-insert>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div id="tm-main" class="uk-section uk-margin-small-top tm-middle uk-padding-remove-top">
|
||||
<div class="tm-main uk-width-1-1@s uk-width-1-1@m uk-width-1-1@l uk-row-first ">
|
||||
|
@ -39,402 +9,401 @@
|
|||
|
||||
|
||||
<div class="uk-margin-top">
|
||||
<div class="uk-grid">
|
||||
<div class="uk-width-expand">
|
||||
<div>
|
||||
<div class=" uk-margin uk-h6 uk-text-primary uk-animation-toggle"
|
||||
(click)="showSources=!showSources; ">
|
||||
SOURCES ({{sources.length + (inlineEntity ? 1 : 0) | number}})
|
||||
<span *ngIf="!showSources" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg" icon="chevron-left"
|
||||
ratio="1"><polyline fill="none" stroke="#000"
|
||||
stroke-width="1.03"
|
||||
points="13 16 7 10 13 4"></polyline></svg></span>
|
||||
<span *ngIf="showSources" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg" icon="chevron-down"
|
||||
ratio="1"><polyline fill="none" stroke="#000"
|
||||
stroke-width="1.03"
|
||||
points="16 7 10 13 4 7"></polyline></svg></span>
|
||||
</div>
|
||||
<ul *ngIf="inlineEntity && showSources" class="uk-list uk-animation-fade">
|
||||
<li
|
||||
[class]="((inlineEntity.warningMessages.length > 0)?' warningBorder ':'')+
|
||||
+((inlineEntity.errorMessages.length > 0)?' dangerBorder ':'') +
|
||||
' uk-alert'" >
|
||||
<div class="uk-grid uk-text-small">
|
||||
<div class="uk-text-muted uk-width-1-2">
|
||||
{{(!inlineEntity.result) ? inlineEntity.type : ((inlineEntity.result && inlineEntity.result.source == 'openaire') ? inlineEntity.type : (inlineEntity.result && inlineEntity.result.source + ' result'))}}
|
||||
</div>
|
||||
<div *ngIf="inlineEntity.errorMessages.length > 0"
|
||||
class="uk-text-danger uk-width-1-2"> Link couldn't be saved
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="uk-text-muted">-->
|
||||
<!-- {{(!inlineEntity.result) ? inlineEntity.type : ((inlineEntity.result && inlineEntity.result.source == 'openaire') ? inlineEntity.type : (inlineEntity.result && inlineEntity.result.source + ' result'))}}-->
|
||||
<!-- </div>-->
|
||||
<div>
|
||||
<claim-title [entity]="inlineEntity"></claim-title>
|
||||
</div>
|
||||
<claim-result-metadata [entity]="inlineEntity"></claim-result-metadata>
|
||||
<claim-project-metadata [entity]="inlineEntity"></claim-project-metadata>
|
||||
</li>
|
||||
</ul>
|
||||
<div *ngIf="!inlineEntity && sources.length == 0 && showSources">
|
||||
|
||||
<div class="uk-alert dangerBorder no-selected-message uk-text-center">
|
||||
<span class="uk-text-bold uk-text-danger"> SOURCES cannot be empty.</span>
|
||||
Start by adding your linking sources first, go to <a (click)="showOptions.showSource() " class="uk-link">
|
||||
sources
|
||||
page</a>.
|
||||
<div class="uk-grid ">
|
||||
<div class="uk-grid uk-width-expand uk-child-width-1-2@m uk-child-width-1-1@s">
|
||||
<!-- Sources-->
|
||||
<div>
|
||||
<div class=" uk-margin uk-animation-toggle">
|
||||
<span class="uk-h6 uk-text-primary "> SOURCES ({{sources.length + (inlineEntity ? 1 : 0) | number}})
|
||||
<!--<span *ngIf="!showSources" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg" icon="chevron-left"
|
||||
ratio="1"><polyline fill="none" stroke="#000"
|
||||
stroke-width="1.03"
|
||||
points="13 16 7 10 13 4"></polyline></svg></span>
|
||||
<span *ngIf="showSources" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg" icon="chevron-down"
|
||||
ratio="1"><polyline fill="none" stroke="#000"
|
||||
stroke-width="1.03"
|
||||
points="16 7 10 13 4 7"></polyline></svg></span>-->
|
||||
</span>
|
||||
<a class="uk-float-right" (click)="showOptions.showSource() "> <span
|
||||
uk-icon="pencil"></span>Edit
|
||||
sources</a>
|
||||
</div>
|
||||
</div>
|
||||
<ul *ngIf="!inlineEntity && sources.length > 0 && showSources" class="uk-list uk-animation-fade">
|
||||
<li *ngFor=" let entity of sources "
|
||||
[class]="((entity.warningMessages.length > 0)?' warningBorder ':'')+
|
||||
+((entity.errorMessages.length > 0)?' dangerBorder ':'') +
|
||||
' uk-alert'">
|
||||
<!-- <div class="uk-text-muted">-->
|
||||
<!-- {{(!entity.result) ? entity.type : ((entity.result && entity.result.source == 'openaire') ? entity.type : (entity.result && entity.result.source + ' result'))}}-->
|
||||
<!-- </div>-->
|
||||
<div class="uk-grid uk-text-small">
|
||||
<div class="uk-text-muted uk-width-1-2">
|
||||
{{(!entity.result) ? entity.type : ((entity.result && entity.result.source == 'openaire') ? entity.type : (entity.result && entity.result.source + ' result'))}}
|
||||
<ul *ngIf="inlineEntity" class="uk-list uk-animation-fade">
|
||||
<li
|
||||
[class]="((inlineEntity.warningMessages.length > 0)?' warningBorder ':'')+
|
||||
+((inlineEntity.errorMessages.length > 0)?' dangerBorder ':'') +
|
||||
' uk-alert'" >
|
||||
<div class="uk-grid uk-text-small">
|
||||
<div class="uk-text-muted uk-width-1-2">
|
||||
{{(!inlineEntity.result) ? inlineEntity.type : ((inlineEntity.result && inlineEntity.result.source == 'openaire') ? inlineEntity.type : (inlineEntity.result && inlineEntity.result.source + ' result'))}}
|
||||
</div>
|
||||
<div *ngIf="inlineEntity.errorMessages.length > 0"
|
||||
class="uk-text-danger uk-width-1-2"> Link couldn't be saved
|
||||
</div>
|
||||
</div>
|
||||
<div *ngIf="entity.errorMessages.length > 0"
|
||||
class="uk-text-danger uk-width-1-2"> Link couldn't be saved
|
||||
<!-- <div class="uk-text-muted">-->
|
||||
<!-- {{(!inlineEntity.result) ? inlineEntity.type : ((inlineEntity.result && inlineEntity.result.source == 'openaire') ? inlineEntity.type : (inlineEntity.result && inlineEntity.result.source + ' result'))}}-->
|
||||
<!-- </div>-->
|
||||
<div>
|
||||
<claim-title [entity]="inlineEntity"></claim-title>
|
||||
</div>
|
||||
<claim-result-metadata [entity]="inlineEntity"></claim-result-metadata>
|
||||
<claim-project-metadata [entity]="inlineEntity"></claim-project-metadata>
|
||||
</li>
|
||||
</ul>
|
||||
<div *ngIf="!inlineEntity && sources.length == 0 ">
|
||||
|
||||
<div class="uk-alert dangerBorder no-selected-message uk-text-center">
|
||||
<span class="uk-text-bold uk-text-danger"> SOURCES cannot be empty.</span>
|
||||
Start by adding your linking sources first, go to <a (click)="showOptions.showSource() " class="uk-link">
|
||||
sources
|
||||
page</a>.
|
||||
</div>
|
||||
</div>
|
||||
<ul *ngIf="!inlineEntity && sources.length > 0 " class="uk-list uk-animation-fade">
|
||||
<li *ngFor=" let entity of sources "
|
||||
[class]="((entity.warningMessages.length > 0)?' warningBorder ':'')+
|
||||
+((entity.errorMessages.length > 0)?' dangerBorder ':'') +
|
||||
' uk-alert'">
|
||||
<!-- <div class="uk-text-muted">-->
|
||||
<!-- {{(!entity.result) ? entity.type : ((entity.result && entity.result.source == 'openaire') ? entity.type : (entity.result && entity.result.source + ' result'))}}-->
|
||||
<!-- </div>-->
|
||||
<div class="uk-grid uk-text-small">
|
||||
<div class="uk-text-muted uk-width-1-2">
|
||||
{{(!entity.result) ? entity.type : ((entity.result && entity.result.source == 'openaire') ? entity.type : (entity.result && entity.result.source + ' result'))}}
|
||||
</div>
|
||||
<div *ngIf="entity.errorMessages.length > 0"
|
||||
class="uk-text-danger uk-width-1-2"> Link couldn't be saved
|
||||
</div>
|
||||
</div>
|
||||
<div class="uk-grid uk-margin-remove-top">
|
||||
<div class="uk-width-expand">
|
||||
<claim-title [entity]="entity"></claim-title>
|
||||
<claim-result-metadata [entity]="entity"></claim-result-metadata>
|
||||
<claim-project-metadata [entity]="entity"></claim-project-metadata>
|
||||
<div *ngIf="entity.result && entity.result.source && entity.result.source!='openaire' "
|
||||
class="uk-grid uk-margin-remove-left uk-margin-small-top uk-text-small">
|
||||
<div class="uk-width-1-2 uk-padding-remove-left">
|
||||
<!-- <span class="uk-text-muted">Type </span>-->
|
||||
<!-- <mat-select [(ngModel)]="entity.type" name="{{'select_type_'+entity.id}}"-->
|
||||
<!-- class="uk-select uk-width-small matSelection"-->
|
||||
<!-- [disableOptionCentering]="true"-->
|
||||
<!-- panelClass="entitiesSelectionPanel">-->
|
||||
<!-- <mat-option [value]="'publication'"-->
|
||||
<!-- (click)="onTypeChanged('publication',entity, false)">Publication-->
|
||||
<!-- </mat-option>-->
|
||||
<!-- <mat-option [value]="'dataset'"-->
|
||||
<!-- (click)="onTypeChanged('dataset',entity, false)">Research data-->
|
||||
<!-- </mat-option>-->
|
||||
<!-- <mat-option [value]="'software'" (click)="onTypeChanged('software',entity, false)">Software-->
|
||||
<!-- </mat-option>-->
|
||||
<!-- <mat-option [value]="'other'"-->
|
||||
<!-- (click)="onTypeChanged('other',entity, false)">Other research product-->
|
||||
<!-- </mat-option>-->
|
||||
<!-- </mat-select>-->
|
||||
|
||||
<mat-form-field class="matSelectionFormField">
|
||||
<mat-label>Type</mat-label>
|
||||
<mat-select [(ngModel)]="entity.type" name="{{'select_type_'+entity.id}}"
|
||||
class="matSelection"
|
||||
[disableOptionCentering]="true"
|
||||
panelClass="entitiesSelectionPanel">
|
||||
<mat-option [value]="'publication'"
|
||||
(click)="onTypeChanged('publication',entity, false)">Publication
|
||||
</mat-option>
|
||||
<mat-option [value]="'dataset'"
|
||||
(click)="onTypeChanged('dataset',entity, false)">Research data
|
||||
</mat-option>
|
||||
<mat-option [value]="'software'" (click)="onTypeChanged('software',entity, false)">Software
|
||||
</mat-option>
|
||||
<mat-option [value]="'other'"
|
||||
(click)="onTypeChanged('other',entity, false)">Other research product
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
</div>
|
||||
<div class="uk-width-1-2">
|
||||
<div class="uk-grid">
|
||||
<!-- <span class="uk-text-muted uk-margin-small-top uk-padding-remove-left">Access mode</span>-->
|
||||
<mat-form-field class="matSelectionFormField">
|
||||
<mat-label>Access mode </mat-label>
|
||||
<mat-select [(ngModel)]="entity.result.accessRights" name="{{'select_rights_'+entity.id}}"
|
||||
class="uk-padding-remove-left matSelection"
|
||||
[disableOptionCentering]="true"
|
||||
panelClass="matSelectionPanel">
|
||||
<mat-option *ngFor="let type of accessTypes" [value]="type"
|
||||
(click)="accessRightsTypeChanged(type,entity, false)">{{type}}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field *ngIf="entity.result.accessRights== 'EMBARGO'">
|
||||
<input matInput [matDatepicker]="picker" placeholder="Choose embargo end date"
|
||||
(click)="picker.open()" [ngModel]="embargoEndDates[entity.id+'_source']"
|
||||
(dateInput)="onDateChanged($event, entity, false)" (dateChange)="onDateChanged($event, entity, false)">
|
||||
<mat-datepicker-toggle matSuffix [for]="picker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #picker [startAt]="embargoEndDates[entity.id+'_source']" ng-model-options="{ timezone: 'utc' }"></mat-datepicker>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div *ngIf="entity.result.accessRights== 'EMBARGO' && getEmbargoEndDateMessage(entity)"
|
||||
[class]="(getEmbargoEndDateMessage(entity)?'uk-text-warning':'')">{{getEmbargoEndDateMessage(entity)}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class=" uk-margin-auto-vertical uk-padding-remove-left uk-margin-small-left">
|
||||
<a class=" uk-icon-button "
|
||||
(click)="remove(entity, false)">
|
||||
<span class="uk-icon">
|
||||
<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="minus"
|
||||
ratio="1"><rect height="1" width="18" y="9" x="1"></rect></svg>
|
||||
</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<!-- Results-->
|
||||
<div>
|
||||
<div class=" uk-margin " >
|
||||
<span class=" uk-h6 uk-text-primary"> LINK TO ({{results.length | number}})</span>
|
||||
|
||||
|
||||
<a class="uk-float-right" (click)="showOptions.show = 'sources';"> <span
|
||||
uk-icon="pencil"></span>Edit
|
||||
entities</a>
|
||||
</div>
|
||||
<div *ngIf="results.length == 0">
|
||||
<div class="uk-alert dangerBorder no-selected-message uk-text-center">
|
||||
<span class="uk-text-bold uk-text-danger"> LINK TO list cannot be empty.</span>
|
||||
Select an entity type to link to:
|
||||
<div class="uk-grid uk-text-center uk-margin-expand uk-padding-small uk-child-width-1-3 uk-width-large uk-margin-auto ">
|
||||
|
||||
<div *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 "
|
||||
(click)="goTo('project')"
|
||||
style="cursor:pointer;">
|
||||
<button class="uk-icon-button portal-button">
|
||||
<span class="uk-icon">
|
||||
<svg height="20" icon="album" ratio="1" viewBox="0 0 20 20" width="20"
|
||||
xmlns="http://www.w3.org/2000/svg"><rect height="1" width="10" x="5" y="2"></rect><rect
|
||||
height="1" width="14" x="3" y="4"></rect><rect fill="none" height="11" stroke="#000"
|
||||
width="17" x="1.5" y="6.5"></rect></svg></span>
|
||||
</button>
|
||||
<div>Projects</div>
|
||||
</div>
|
||||
<div *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " (click)="goTo('result')"
|
||||
style="cursor:pointer;">
|
||||
<button class="uk-icon-button portal-button">
|
||||
<span class="uk-icon">
|
||||
<svg height="20" icon="copy" ratio="1" viewBox="0 0 20 20" width="20"
|
||||
xmlns="http://www.w3.org/2000/svg"><rect fill="none" height="16" stroke="#000"
|
||||
width="12" x="3.5" y="2.5"></rect><polyline
|
||||
fill="none" points="5 0.5 17.5 0.5 17.5 17" stroke="#000"></polyline></svg></span>
|
||||
</button>
|
||||
<div>Research results</div>
|
||||
</div>
|
||||
<div *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 "
|
||||
(click)="goTo('context')"
|
||||
style="cursor:pointer;">
|
||||
<button class="uk-icon-button portal-button">
|
||||
<span class="uk-icon">
|
||||
<svg height="20" icon="users" ratio="1" viewBox="0 0 20 20" width="20"
|
||||
xmlns="http://www.w3.org/2000/svg"><circle cx="7.7" cy="8.6" fill="none" r="3.5"
|
||||
stroke="#000" stroke-width="1.1"></circle><path
|
||||
d="M1,18.1 C1.7,14.6 4.4,12.1 7.6,12.1 C10.9,12.1 13.7,14.8 14.3,18.3" fill="none"
|
||||
stroke="#000" stroke-width="1.1"></path><path
|
||||
d="M11.4,4 C12.8,2.4 15.4,2.8 16.3,4.7 C17.2,6.6 15.7,8.9 13.6,8.9 C16.5,8.9 18.8,11.3 19.2,14.1"
|
||||
fill="none" stroke="#000" stroke-width="1.1"></path></svg></span>
|
||||
</button>
|
||||
<div>Communities</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="uk-grid uk-margin-remove-top">
|
||||
<div class="uk-width-expand">
|
||||
<claim-title [entity]="entity"></claim-title>
|
||||
<claim-result-metadata [entity]="entity"></claim-result-metadata>
|
||||
<claim-project-metadata [entity]="entity"></claim-project-metadata>
|
||||
<div *ngIf="entity.result && entity.result.source && entity.result.source!='openaire' "
|
||||
class="uk-grid uk-margin-remove-left uk-margin-small-top uk-text-small">
|
||||
<div class="uk-width-1-2 uk-padding-remove-left">
|
||||
<!-- <span class="uk-text-muted">Type </span>-->
|
||||
<!-- <mat-select [(ngModel)]="entity.type" name="{{'select_type_'+entity.id}}"-->
|
||||
<!-- class="uk-select uk-width-small matSelection"-->
|
||||
<!-- [disableOptionCentering]="true"-->
|
||||
<!-- panelClass="entitiesSelectionPanel">-->
|
||||
<!-- <mat-option [value]="'publication'"-->
|
||||
<!-- (click)="onTypeChanged('publication',entity, false)">Publication-->
|
||||
<!-- </mat-option>-->
|
||||
<!-- <mat-option [value]="'dataset'"-->
|
||||
<!-- (click)="onTypeChanged('dataset',entity, false)">Research data-->
|
||||
<!-- </mat-option>-->
|
||||
<!-- <mat-option [value]="'software'" (click)="onTypeChanged('software',entity, false)">Software-->
|
||||
<!-- </mat-option>-->
|
||||
<!-- <mat-option [value]="'other'"-->
|
||||
<!-- (click)="onTypeChanged('other',entity, false)">Other research product-->
|
||||
<!-- </mat-option>-->
|
||||
<!-- </mat-select>-->
|
||||
|
||||
<mat-form-field class="matSelectionFormField">
|
||||
<mat-label>Type</mat-label>
|
||||
</div>
|
||||
<ul *ngIf="results.length > 0 " class="uk-list uk-animation-fade">
|
||||
<li *ngFor=" let entity of results "
|
||||
[class]="((entity.warningMessages.length > 0)?' warningBorder ':'')+
|
||||
+((entity.errorMessages.length > 0)?' dangerBorder ':'') +
|
||||
' uk-alert'" style="z-index: 0 !important;">
|
||||
<div class="uk-grid uk-text-small">
|
||||
<div class="uk-text-muted uk-width-1-2">
|
||||
{{(!entity.result) ? entity.type : ((entity.result && entity.result.source == 'openaire') ? entity.type : (entity.result && entity.result.source + ' result'))}}
|
||||
</div>
|
||||
<div *ngIf="entity.errorMessages.length > 0"
|
||||
class="uk-text-danger uk-width-1-2"> Link couldn't be saved
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="uk-grid uk-margin-remove-top">
|
||||
<div class="uk-width-expand">
|
||||
|
||||
<claim-title [entity]="entity"></claim-title>
|
||||
<claim-result-metadata [entity]="entity"></claim-result-metadata>
|
||||
<claim-project-metadata [entity]="entity"></claim-project-metadata>
|
||||
<div *ngIf="entity.result && entity.result.source && entity.result.source!='openaire' "
|
||||
class="uk-grid uk-text-small uk-margin-remove-left uk-margin-small-top">
|
||||
<div class="uk-width-1-2 uk-padding-remove-left">
|
||||
<!-- <span class="uk-text-muted">Type </span>-->
|
||||
<mat-form-field class="matSelectionFormField">
|
||||
<mat-label>Type</mat-label>
|
||||
<mat-select [(ngModel)]="entity.type" name="{{'select_type_'+entity.id}}"
|
||||
class="matSelection"
|
||||
[disableOptionCentering]="true"
|
||||
panelClass="entitiesSelectionPanel">
|
||||
class=" matSelection"
|
||||
[disableOptionCentering]="true"
|
||||
panelClass="matSelectionPanel">
|
||||
<mat-option [value]="'publication'"
|
||||
(click)="onTypeChanged('publication',entity, false)">Publication
|
||||
(click)="onTypeChanged('publication',entity, false)">Publication
|
||||
</mat-option>
|
||||
<mat-option [value]="'dataset'"
|
||||
(click)="onTypeChanged('dataset',entity, false)">Research data
|
||||
(click)="onTypeChanged('dataset',entity, false)">Research data
|
||||
</mat-option>
|
||||
<mat-option [value]="'software'" (click)="onTypeChanged('software',entity, false)">Software
|
||||
</mat-option>
|
||||
<mat-option [value]="'other'"
|
||||
(click)="onTypeChanged('other',entity, false)">Other research product
|
||||
(click)="onTypeChanged('other',entity, false)">Other research product
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
</div>
|
||||
<div class="uk-width-1-2">
|
||||
<div class="uk-grid">
|
||||
<!-- <span class="uk-text-muted uk-margin-small-top uk-padding-remove-left">Access mode</span>-->
|
||||
<mat-form-field class="matSelectionFormField">
|
||||
<mat-label>Access mode </mat-label>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div class="uk-width-1-2">
|
||||
<div class="uk-grid">
|
||||
<!-- <span class="uk-text-muted uk-margin-small-top uk-padding-remove-left">Access mode</span>-->
|
||||
<mat-form-field class="matSelectionFormField">
|
||||
<mat-label>Access mode </mat-label>
|
||||
<mat-select [(ngModel)]="entity.result.accessRights" name="{{'select_rights_'+entity.id}}"
|
||||
class="uk-padding-remove-left matSelection"
|
||||
class=" uk-padding-remove-left matSelection"
|
||||
[disableOptionCentering]="true"
|
||||
panelClass="matSelectionPanel">
|
||||
<mat-option *ngFor="let type of accessTypes" [value]="type"
|
||||
(click)="accessRightsTypeChanged(type,entity, false)">{{type}}</mat-option>
|
||||
(click)="accessRightsTypeChanged(type,entity, true)">{{type}}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field *ngIf="entity.result.accessRights== 'EMBARGO'">
|
||||
<input matInput [matDatepicker]="picker" placeholder="Choose embargo end date"
|
||||
(click)="picker.open()" [ngModel]="embargoEndDates[entity.id+'_source']"
|
||||
(dateInput)="onDateChanged($event, entity, false)" (dateChange)="onDateChanged($event, entity, false)">
|
||||
<mat-datepicker-toggle matSuffix [for]="picker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #picker [startAt]="embargoEndDates[entity.id+'_source']" ng-model-options="{ timezone: 'utc' }"></mat-datepicker>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div *ngIf="entity.result.accessRights== 'EMBARGO' && getEmbargoEndDateMessage(entity)"
|
||||
[class]="(getEmbargoEndDateMessage(entity)?'uk-text-warning':'')">{{getEmbargoEndDateMessage(entity)}}
|
||||
</mat-form-field>
|
||||
<mat-form-field *ngIf="entity.result.accessRights== 'EMBARGO'">
|
||||
<input matInput [matDatepicker]="picker" placeholder="Choose embargo end date"
|
||||
(click)="picker.open()" [ngModel]="embargoEndDates[entity.id+'_result']"
|
||||
(dateInput)="onDateChanged($event, entity, true)"
|
||||
(dateChange)="onDateChanged($event, entity, true)">
|
||||
<mat-datepicker-toggle matSuffix [for]="picker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #picker [startAt]="embargoEndDates[entity.id+'_result']" ng-model-options="{ timezone: 'utc' }"></mat-datepicker>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div *ngIf="entity.result.accessRights== 'EMBARGO' && getEmbargoEndDateMessage(entity)"
|
||||
[class]="(getEmbargoEndDateMessage(entity)?'uk-text-warning':'')">{{getEmbargoEndDateMessage(entity)}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="uk-margin-auto-vertical uk-padding-remove-left uk-margin-small-left">
|
||||
<a class="uk-icon-button "
|
||||
(click)="remove(entity, true)">
|
||||
<span class="uk-icon">
|
||||
<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="minus"
|
||||
ratio="1"><rect height="1" width="18" y="9" x="1"></rect></svg>
|
||||
</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class=" uk-margin-auto-vertical uk-padding-remove-left uk-margin-small-left">
|
||||
<a class=" uk-icon-button "
|
||||
(click)="remove(entity, false)">
|
||||
<span class="uk-icon">
|
||||
<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="minus"
|
||||
ratio="1"><rect height="1" width="18" y="9" x="1"></rect></svg>
|
||||
</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<!-- Results-->
|
||||
<div>
|
||||
<div class=" uk-margin uk-h6 uk-text-primary "
|
||||
(click)="showLinksTo=!showLinksTo; ">
|
||||
LINK TO ({{results.length | number}})
|
||||
|
||||
<span *ngIf="!showLinksTo" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
icon="chevron-left" ratio="1"><polyline
|
||||
fill="none" stroke="#000" stroke-width="1.03" points="13 16 7 10 13 4"></polyline></svg></span>
|
||||
<span *ngIf="showLinksTo" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
icon="chevron-down" ratio="1"><polyline
|
||||
fill="none" stroke="#000" stroke-width="1.03" points="16 7 10 13 4 7"></polyline></svg></span>
|
||||
|
||||
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div *ngIf="results.length == 0 && showLinksTo">
|
||||
<div class="uk-alert dangerBorder no-selected-message uk-text-center">
|
||||
<span class="uk-text-bold uk-text-danger"> LINK TO list cannot be empty.</span>
|
||||
Select an entity type to link to:
|
||||
<div class="uk-grid uk-text-center uk-margin-expand uk-padding-small uk-child-width-1-3 uk-width-large uk-margin-auto ">
|
||||
|
||||
<div *ngIf="showOptions.linkToEntities.indexOf('project')!=-1 "
|
||||
(click)="goTo('project')"
|
||||
style="cursor:pointer;">
|
||||
<button class="uk-icon-button portal-button">
|
||||
<span class="uk-icon">
|
||||
<svg height="20" icon="album" ratio="1" viewBox="0 0 20 20" width="20"
|
||||
xmlns="http://www.w3.org/2000/svg"><rect height="1" width="10" x="5" y="2"></rect><rect
|
||||
height="1" width="14" x="3" y="4"></rect><rect fill="none" height="11" stroke="#000"
|
||||
width="17" x="1.5" y="6.5"></rect></svg></span>
|
||||
</button>
|
||||
<div>Projects</div>
|
||||
</div>
|
||||
<div *ngIf="showOptions.linkToEntities.indexOf('result')!=-1 " (click)="goTo('result')"
|
||||
style="cursor:pointer;">
|
||||
<button class="uk-icon-button portal-button">
|
||||
<span class="uk-icon">
|
||||
<svg height="20" icon="copy" ratio="1" viewBox="0 0 20 20" width="20"
|
||||
xmlns="http://www.w3.org/2000/svg"><rect fill="none" height="16" stroke="#000"
|
||||
width="12" x="3.5" y="2.5"></rect><polyline
|
||||
fill="none" points="5 0.5 17.5 0.5 17.5 17" stroke="#000"></polyline></svg></span>
|
||||
</button>
|
||||
<div>Research results</div>
|
||||
</div>
|
||||
<div *ngIf="showOptions.linkToEntities.indexOf('context')!=-1 "
|
||||
(click)="goTo('context')"
|
||||
style="cursor:pointer;">
|
||||
<button class="uk-icon-button portal-button">
|
||||
<span class="uk-icon">
|
||||
<svg height="20" icon="users" ratio="1" viewBox="0 0 20 20" width="20"
|
||||
xmlns="http://www.w3.org/2000/svg"><circle cx="7.7" cy="8.6" fill="none" r="3.5"
|
||||
stroke="#000" stroke-width="1.1"></circle><path
|
||||
d="M1,18.1 C1.7,14.6 4.4,12.1 7.6,12.1 C10.9,12.1 13.7,14.8 14.3,18.3" fill="none"
|
||||
stroke="#000" stroke-width="1.1"></path><path
|
||||
d="M11.4,4 C12.8,2.4 15.4,2.8 16.3,4.7 C17.2,6.6 15.7,8.9 13.6,8.9 C16.5,8.9 18.8,11.3 19.2,14.1"
|
||||
fill="none" stroke="#000" stroke-width="1.1"></path></svg></span>
|
||||
</button>
|
||||
<div>Communities</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<ul *ngIf="results.length > 0 && showLinksTo" class="uk-list uk-animation-fade">
|
||||
<li *ngFor=" let entity of results "
|
||||
[class]="((entity.warningMessages.length > 0)?' warningBorder ':'')+
|
||||
+((entity.errorMessages.length > 0)?' dangerBorder ':'') +
|
||||
' uk-alert'" style="z-index: 0 !important;">
|
||||
<div class="uk-grid uk-text-small">
|
||||
<div class="uk-text-muted uk-width-1-2">
|
||||
{{(!entity.result) ? entity.type : ((entity.result && entity.result.source == 'openaire') ? entity.type : (entity.result && entity.result.source + ' result'))}}
|
||||
</div>
|
||||
<div *ngIf="entity.errorMessages.length > 0"
|
||||
class="uk-text-danger uk-width-1-2"> Link couldn't be saved
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="uk-grid uk-margin-remove-top">
|
||||
<div class="uk-width-expand">
|
||||
|
||||
<claim-title [entity]="entity"></claim-title>
|
||||
<claim-result-metadata [entity]="entity"></claim-result-metadata>
|
||||
<claim-project-metadata [entity]="entity"></claim-project-metadata>
|
||||
<div *ngIf="entity.result && entity.result.source && entity.result.source!='openaire' "
|
||||
class="uk-grid uk-text-small uk-margin-remove-left uk-margin-small-top">
|
||||
<div class="uk-width-1-2 uk-padding-remove-left">
|
||||
<!-- <span class="uk-text-muted">Type </span>-->
|
||||
<mat-form-field class="matSelectionFormField">
|
||||
<mat-label>Type</mat-label>
|
||||
<mat-select [(ngModel)]="entity.type" name="{{'select_type_'+entity.id}}"
|
||||
class=" matSelection"
|
||||
[disableOptionCentering]="true"
|
||||
panelClass="matSelectionPanel">
|
||||
<mat-option [value]="'publication'"
|
||||
(click)="onTypeChanged('publication',entity, false)">Publication
|
||||
</mat-option>
|
||||
<mat-option [value]="'dataset'"
|
||||
(click)="onTypeChanged('dataset',entity, false)">Research data
|
||||
</mat-option>
|
||||
<mat-option [value]="'software'" (click)="onTypeChanged('software',entity, false)">Software
|
||||
</mat-option>
|
||||
<mat-option [value]="'other'"
|
||||
(click)="onTypeChanged('other',entity, false)">Other research product
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div class="uk-width-1-2">
|
||||
<div class="uk-grid">
|
||||
<!-- <span class="uk-text-muted uk-margin-small-top uk-padding-remove-left">Access mode</span>-->
|
||||
<mat-form-field class="matSelectionFormField">
|
||||
<mat-label>Access mode </mat-label>
|
||||
<mat-select [(ngModel)]="entity.result.accessRights" name="{{'select_rights_'+entity.id}}"
|
||||
class=" uk-padding-remove-left matSelection"
|
||||
[disableOptionCentering]="true"
|
||||
panelClass="matSelectionPanel">
|
||||
<mat-option *ngFor="let type of accessTypes" [value]="type"
|
||||
(click)="accessRightsTypeChanged(type,entity, true)">{{type}}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field *ngIf="entity.result.accessRights== 'EMBARGO'">
|
||||
<input matInput [matDatepicker]="picker" placeholder="Choose embargo end date"
|
||||
(click)="picker.open()" [ngModel]="embargoEndDates[entity.id+'_result']"
|
||||
(dateInput)="onDateChanged($event, entity, true)"
|
||||
(dateChange)="onDateChanged($event, entity, true)">
|
||||
<mat-datepicker-toggle matSuffix [for]="picker"></mat-datepicker-toggle>
|
||||
<mat-datepicker #picker [startAt]="embargoEndDates[entity.id+'_result']" ng-model-options="{ timezone: 'utc' }"></mat-datepicker>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<div *ngIf="entity.result.accessRights== 'EMBARGO' && getEmbargoEndDateMessage(entity)"
|
||||
[class]="(getEmbargoEndDateMessage(entity)?'uk-text-warning':'')">{{getEmbargoEndDateMessage(entity)}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="uk-margin-auto-vertical uk-padding-remove-left uk-margin-small-left">
|
||||
<a class="uk-icon-button "
|
||||
(click)="remove(entity, true)">
|
||||
<span class="uk-icon">
|
||||
<svg width="20" height="20" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" icon="minus"
|
||||
ratio="1"><rect height="1" width="18" y="9" x="1"></rect></svg>
|
||||
</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="uk-section uk-padding-remove-top uk-padding-remove-bottom uk-width-1-1">
|
||||
<div
|
||||
[class]="((defaultColors)?'linkingToolbar':'communityPanelBackground')+' uk-padding-small'">
|
||||
<div class="uk-container uk-container-large uk-margin-small-top uk-padding-small">
|
||||
<div class="uk-grid uk-flex uk-flex-center">
|
||||
|
||||
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="uk-width-1-3" *ngIf="errors.length > 0 || warnings.length > 0">
|
||||
<!-- Errors and Warning -->
|
||||
<div *ngIf="errors.length > 0" class=" uk-margin uk-h6 uk-text-primary uk-animation-toggle"
|
||||
(click)="showErrors=!showErrors ">
|
||||
ERRORS ({{errors.length | number}})
|
||||
<span *ngIf="!showErrors" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
icon="chevron-left" ratio="1"><polyline
|
||||
fill="none" stroke="#000" stroke-width="1.03" points="13 16 7 10 13 4"></polyline></svg></span>
|
||||
<span *ngIf="showErrors" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
icon="chevron-down" ratio="1"><polyline
|
||||
fill="none" stroke="#000" stroke-width="1.03" points="16 7 10 13 4 7"></polyline></svg></span>
|
||||
</div>
|
||||
<div *ngIf="errors.length > 0 && showErrors" class=" uk-animation-fade">
|
||||
<div *ngFor=" let message of errors " class="uk-alert dangerBorder">
|
||||
<div *ngIf="message.type == 'claimServiceFail2Insert'">
|
||||
<div class="">
|
||||
|
||||
<span class="uk-text-danger uk-text-bold"> Fail to save {{message.failed|number}}
|
||||
{{message.failed > 1 ? 'links.' : 'link.'}}</span>
|
||||
<br>
|
||||
<div
|
||||
*ngIf="message.inserted>0">But {{message.inserted|number}} link{{message.inserted > 1 ? 's' : ''}} was
|
||||
successfully inserted.
|
||||
<div>
|
||||
<a routerLinkActive="router-link-active" routerLink="/myclaims">Manage your links here</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div *ngIf="message.type == 'claimServiceFail'">
|
||||
|
||||
<div class="">
|
||||
<span class="uk-text-danger uk-text-bold"> An error occured while saving your links.</span>
|
||||
<br>
|
||||
None of the links saved.
|
||||
<claim-insert [results]="results" [sources]="sources" [inlineEntity]="inlineEntity"
|
||||
[properties]=properties [localStoragePrefix]=localStoragePrefix
|
||||
class=" " [errors]="errors" (insertFinished)="runValidation(false); updateLocalStorage();"
|
||||
[defaultColors]="defaultColors" [communityId]="communityId">
|
||||
</claim-insert>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div *ngIf="warnings.length > 0"
|
||||
class=" uk-margin uk-h6 uk-text-primary uk-animation-toggle"
|
||||
(click)="showWarnings=!showWarnings "> WARNINGS
|
||||
({{warnings.length
|
||||
| number}})
|
||||
<span *ngIf="!showWarnings" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
icon="chevron-left" ratio="1"><polyline
|
||||
fill="none" stroke="#000" stroke-width="1.03" points="13 16 7 10 13 4"></polyline></svg></span>
|
||||
<span *ngIf="showWarnings" class="uk-icon"><svg width="20" height="20" viewBox="0 0 20 20"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
icon="chevron-down" ratio="1"><polyline
|
||||
fill="none" stroke="#000" stroke-width="1.03" points="16 7 10 13 4 7"></polyline></svg></span>
|
||||
</div>
|
||||
|
||||
<div *ngIf="warnings.length > 0 && showWarnings " class=" uk-animation-fade">
|
||||
<div *ngFor=" let message of warnings " class="uk-alert warningBorder">
|
||||
<div *ngIf="message.type == 'embargoEndDate'">
|
||||
<div class="uk-text-warning uk-text-bold">
|
||||
Embargo date must be later than published date in
|
||||
|
||||
<div class="uk-width-1-3" *ngIf="errors.length > 0 || warnings.length > 0">
|
||||
<!-- Errors and Warning -->
|
||||
<div *ngIf="errors.length > 0" class=" uk-margin uk-h6 uk-text-danger uk-animation-toggle" >
|
||||
ERRORS ({{errors.length | number}})
|
||||
|
||||
</div>
|
||||
<div *ngIf="errors.length > 0 " class="">
|
||||
<div *ngFor=" let message of errors " class="uk-alert uk-alert-danger">
|
||||
<div *ngIf="message.type == 'claimServiceFail2Insert'">
|
||||
<div class="">
|
||||
|
||||
<span class=" uk-text-bold"> Fail to save {{message.failed|number}}
|
||||
{{message.failed > 1 ? 'links.' : 'link.'}}</span>
|
||||
<br>
|
||||
<div
|
||||
*ngIf="message.inserted>0">But {{message.inserted|number}} link{{message.inserted > 1 ? 's' : ''}} was
|
||||
successfully inserted.
|
||||
<div>
|
||||
<a routerLinkActive="router-link-active" routerLink="/myclaims">Manage your links here</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="">
|
||||
{{message.resultTitle}}
|
||||
|
||||
<div *ngIf="message.type == 'claimServiceFail'">
|
||||
|
||||
<div class="">
|
||||
<span class=" uk-text-bold"> An error occured while saving your links.</span>
|
||||
<br>
|
||||
None of the links saved.
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div *ngIf="message.type == 'projectDuration'">
|
||||
<div class="uk-text-warning uk-text-bold">
|
||||
Published date must be in the project's date boundaries
|
||||
(from {{message.projectInfo.startDate}}{{(message.projectInfo.endDate) ? (' to ' + (addStringToNumber(message.projectInfo.endDate, 5))) : ''}}) in
|
||||
</div>
|
||||
<div *ngIf="warnings.length > 0"
|
||||
class=" uk-margin uk-h6 uk-text-warning uk-animation-toggle"> WARNINGS
|
||||
({{warnings.length
|
||||
| number}})
|
||||
|
||||
</div>
|
||||
|
||||
<div *ngIf="warnings.length > 0 " class="">
|
||||
<div *ngFor=" let message of warnings " class="uk-alert uk-alert-warning">
|
||||
<div *ngIf="message.type == 'embargoEndDate'">
|
||||
<div class="uk-text-bold">
|
||||
Embargo date must be later than published date in
|
||||
</div>
|
||||
<div class="">
|
||||
{{message.resultTitle}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="">
|
||||
{{message.resultTitle}}
|
||||
</div>
|
||||
<div class="uk-text-muted uk-text-small">
|
||||
with link to
|
||||
</div>
|
||||
<div class="">
|
||||
{{message.projectInfo.title}}
|
||||
</div>
|
||||
<div><span class="uk-text-muted uk-text-small">
|
||||
Project boundaries: </span>({{message.projectInfo.startDate}}{{(message.projectInfo.endDate) ? (' - ' + (message.projectInfo.endDate) + ') +5 years') : ')'}}
|
||||
<div *ngIf="message.type == 'projectDuration'">
|
||||
<div class="uk-text-bold">
|
||||
Published date must be in the project's date boundaries
|
||||
(from {{message.projectInfo.startDate}}{{(message.projectInfo.endDate) ? (' to ' + (addStringToNumber(message.projectInfo.endDate, 5))) : ''}}) in
|
||||
</div>
|
||||
<div class="">
|
||||
{{message.resultTitle}}
|
||||
</div>
|
||||
<div class="uk-text-muted uk-text-small">
|
||||
with link to
|
||||
</div>
|
||||
<div class="">
|
||||
{{message.projectInfo.title}}
|
||||
</div>
|
||||
<div><span class="uk-text-muted uk-text-small">
|
||||
Project boundaries: </span>({{message.projectInfo.startDate}}{{(message.projectInfo.endDate) ? (' - ' + (message.projectInfo.endDate) + ') +5 years') : ')'}}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<modal-alert (alertOutput)="confirmClose()">
|
||||
</modal-alert>
|
||||
</div>
|
||||
|
@ -444,10 +413,11 @@
|
|||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<helper *ngIf="pageContents && pageContents['bottom'] && pageContents['bottom'].length > 0" [texts]="pageContents['bottom']"></helper>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -12,10 +12,10 @@ import {HelperFunctions} from "../../../utils/HelperFunctions.class";
|
|||
})
|
||||
export class MetadataPreviewComponent {
|
||||
|
||||
showSources = true;
|
||||
showLinksTo = true;
|
||||
showErrors = true;
|
||||
showWarnings = true;
|
||||
/* showSources = true;
|
||||
showLinksTo = true;*/
|
||||
// showErrors = true;
|
||||
// showWarnings = true;
|
||||
@Input() results: ClaimEntity[];
|
||||
@Input() sources: ClaimEntity[];
|
||||
@Input() title: string = "Research Results";
|
||||
|
@ -40,10 +40,10 @@ export class MetadataPreviewComponent {
|
|||
|
||||
ngOnInit() {
|
||||
this.setEmbargoEndDates();
|
||||
if (this.inlineEntity) {
|
||||
/* if (this.inlineEntity) {
|
||||
this.showSources = true;
|
||||
this.showLinksTo = true;
|
||||
}
|
||||
}*/
|
||||
this.runValidation(true);
|
||||
}
|
||||
setEmbargoEndDates(){
|
||||
|
|
|
@ -6,7 +6,7 @@ export class ConnectHelper {
|
|||
|
||||
public static getCommunityFromDomain(domain: string): string{
|
||||
if(properties.environment == "development") {
|
||||
// domain = "aginfra.openaire.eu"; //for testing
|
||||
domain = "covid-19.openaire.eu"; //for testing
|
||||
}
|
||||
domain = domain.indexOf("//") != -1? domain.split("//")[1]:domain; //remove https:// prefix
|
||||
if (domain.indexOf('eosc-portal.eu') != -1) {
|
||||
|
|
Loading…
Reference in New Issue