Revision 45786
Added by Argiro Kokogiannaki about 7 years ago
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositDatasets.component.ts | ||
---|---|---|
1 |
import {Component} from '@angular/core'; |
|
2 |
|
|
3 |
@Component({ |
|
4 |
selector: 'deposit-datasets', |
|
5 |
template: ` |
|
6 |
<deposit [compatibility]="'Registry of Research Data Repository'" [requestFor]="'Research Data'"></deposit> |
|
7 |
` |
|
8 |
}) |
|
9 |
|
|
10 |
export class DepositDatasetsComponent { |
|
11 |
|
|
12 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositPublications.component.ts | ||
---|---|---|
1 |
import {Component} from '@angular/core'; |
|
2 |
|
|
3 |
@Component({ |
|
4 |
selector: 'deposit-publications', |
|
5 |
template: ` |
|
6 |
<deposit [compatibility]="'OpenDOAR'" [requestFor]="'Publications'"></deposit> |
|
7 |
<h3>Or locate data provider in map</h3> |
|
8 |
<div class="uk-margin-top"> |
|
9 |
<i-frame [url]="mapUrl"width="100%" height="900"></i-frame> |
|
10 |
</div> |
|
11 |
` |
|
12 |
}) |
|
13 |
|
|
14 |
export class DepositPublicationsComponent { |
|
15 |
public mapUrl ="https://beta.openaire.eu/stats/markers-demo.html"; |
|
16 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositDatasets-routing.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { RouterModule } from '@angular/router'; |
|
3 |
|
|
4 |
import { DepositDatasetsComponent } from './depositDatasets.component'; |
|
5 |
import { DepositDatasetsResultComponent } from './depositDatasetsResult.component'; |
|
6 |
|
|
7 |
@NgModule({ |
|
8 |
imports: [ |
|
9 |
RouterModule.forChild([ |
|
10 |
{ path: '', component: DepositDatasetsComponent } |
|
11 |
|
|
12 |
]) |
|
13 |
] |
|
14 |
}) |
|
15 |
export class DepositDatasetsRoutingModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositDatasetsResult.component.ts | ||
---|---|---|
1 |
import {Component} from '@angular/core'; |
|
2 |
|
|
3 |
@Component({ |
|
4 |
selector: 'deposit-datasets-result', |
|
5 |
template: ` |
|
6 |
<deposit-result [compatibility]="'Registry of Research Data Repository'" [requestFor]="'Research Data'"></deposit-result> |
|
7 |
` |
|
8 |
}) |
|
9 |
|
|
10 |
export class DepositDatasetsResultComponent { |
|
11 |
|
|
12 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositPublications-routing.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { RouterModule } from '@angular/router'; |
|
3 |
|
|
4 |
import { DepositPublicationsComponent } from './depositPublications.component'; |
|
5 |
|
|
6 |
@NgModule({ |
|
7 |
imports: [ |
|
8 |
RouterModule.forChild([ |
|
9 |
{ path: '', component: DepositPublicationsComponent } |
|
10 |
|
|
11 |
]) |
|
12 |
] |
|
13 |
}) |
|
14 |
export class DepositPublicationsRoutingModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositDatasetsResults-routing.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { RouterModule } from '@angular/router'; |
|
3 |
|
|
4 |
import { DepositDatasetsResultComponent } from './depositDatasetsResult.component'; |
|
5 |
|
|
6 |
@NgModule({ |
|
7 |
imports: [ |
|
8 |
RouterModule.forChild([ |
|
9 |
{ path: '', component: DepositDatasetsResultComponent } |
|
10 |
|
|
11 |
]) |
|
12 |
] |
|
13 |
}) |
|
14 |
export class DepositDatasetsResultsRoutingModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositPublicationsResult.component.ts | ||
---|---|---|
1 |
import {Component} from '@angular/core'; |
|
2 |
|
|
3 |
@Component({ |
|
4 |
selector: 'deposit-publications-result', |
|
5 |
template: ` |
|
6 |
<deposit-result [compatibility]="'OpenDOAR'" [requestFor]="'Publications'"></deposit-result> |
|
7 |
` |
|
8 |
}) |
|
9 |
|
|
10 |
export class DepositPublicationsResultComponent { |
|
11 |
|
|
12 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositDatasetsResults.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { CommonModule } from '@angular/common'; |
|
3 |
import { FormsModule } from '@angular/forms'; |
|
4 |
|
|
5 |
import { DepositDatasetsResultComponent } from './depositDatasetsResult.component'; |
|
6 |
|
|
7 |
import {DepositDatasetsResultsRoutingModule} from './depositDatasetsResults-routing.module'; |
|
8 |
import {DepoditModule} from './deposit.module'; |
|
9 |
|
|
10 |
@NgModule({ |
|
11 |
imports: [ |
|
12 |
CommonModule, FormsModule, |
|
13 |
DepoditModule, |
|
14 |
DepositDatasetsResultsRoutingModule |
|
15 |
], |
|
16 |
declarations: [ |
|
17 |
|
|
18 |
DepositDatasetsResultComponent, |
|
19 |
|
|
20 |
], |
|
21 |
exports: [ |
|
22 |
DepositDatasetsResultComponent, |
|
23 |
], |
|
24 |
providers: [ |
|
25 |
] |
|
26 |
}) |
|
27 |
export class DepositDatasetsResultsModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositPublicationsResult-routing.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { RouterModule } from '@angular/router'; |
|
3 |
|
|
4 |
import { DepositPublicationsResultComponent } from './depositPublicationsResult.component'; |
|
5 |
|
|
6 |
@NgModule({ |
|
7 |
imports: [ |
|
8 |
RouterModule.forChild([ |
|
9 |
{ path: '', component: DepositPublicationsResultComponent } |
|
10 |
|
|
11 |
]) |
|
12 |
] |
|
13 |
}) |
|
14 |
export class DepositPublicationsResultRoutingModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositPublicationsResults.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { CommonModule } from '@angular/common'; |
|
3 |
import { FormsModule } from '@angular/forms'; |
|
4 |
|
|
5 |
import { DepositPublicationsResultComponent } from './depositPublicationsResult.component'; |
|
6 |
|
|
7 |
import {DepositPublicationsResultRoutingModule} from './depositPublicationsResult-routing.module'; |
|
8 |
import {DepoditModule} from './deposit.module'; |
|
9 |
|
|
10 |
@NgModule({ |
|
11 |
imports: [ |
|
12 |
CommonModule, FormsModule, |
|
13 |
DepoditModule, |
|
14 |
DepositPublicationsResultRoutingModule |
|
15 |
], |
|
16 |
declarations: [ |
|
17 |
|
|
18 |
DepositPublicationsResultComponent, |
|
19 |
|
|
20 |
], |
|
21 |
exports: [ |
|
22 |
DepositPublicationsResultComponent, |
|
23 |
], |
|
24 |
providers: [ |
|
25 |
] |
|
26 |
}) |
|
27 |
export class DepositPublicationsResultsModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositDatasets.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { CommonModule } from '@angular/common'; |
|
3 |
import { FormsModule } from '@angular/forms'; |
|
4 |
|
|
5 |
import { DepositDatasetsComponent } from './depositDatasets.component'; |
|
6 |
import { DepositDatasetsResultComponent } from './depositDatasetsResult.component'; |
|
7 |
|
|
8 |
import {DepositDatasetsRoutingModule} from './depositDatasets-routing.module'; |
|
9 |
import {DepoditModule} from './deposit.module'; |
|
10 |
|
|
11 |
@NgModule({ |
|
12 |
imports: [ |
|
13 |
CommonModule, FormsModule, |
|
14 |
DepoditModule, |
|
15 |
DepositDatasetsRoutingModule |
|
16 |
], |
|
17 |
declarations: [ |
|
18 |
|
|
19 |
DepositDatasetsComponent, |
|
20 |
|
|
21 |
], |
|
22 |
exports: [ |
|
23 |
DepositDatasetsComponent, |
|
24 |
], |
|
25 |
providers: [ |
|
26 |
] |
|
27 |
}) |
|
28 |
export class DepositDatasetsModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/depositPublications.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { CommonModule } from '@angular/common'; |
|
3 |
import { FormsModule } from '@angular/forms'; |
|
4 |
|
|
5 |
import { DepositPublicationsComponent } from './depositPublications.component'; |
|
6 |
|
|
7 |
import {DepositPublicationsRoutingModule} from './depositPublications-routing.module'; |
|
8 |
import {DepoditModule} from './deposit.module'; |
|
9 |
import {IFrameModule} from '../utils/iframe.module'; |
|
10 |
|
|
11 |
@NgModule({ |
|
12 |
imports: [ |
|
13 |
CommonModule, FormsModule, |
|
14 |
DepoditModule, |
|
15 |
DepositPublicationsRoutingModule,IFrameModule |
|
16 |
], |
|
17 |
declarations: [ |
|
18 |
|
|
19 |
DepositPublicationsComponent, |
|
20 |
|
|
21 |
], |
|
22 |
exports: [ |
|
23 |
DepositPublicationsComponent, |
|
24 |
], |
|
25 |
providers: [ |
|
26 |
] |
|
27 |
}) |
|
28 |
export class DepositPublicationsModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/app-routing.module.ts | ||
---|---|---|
22 | 22 |
.then(mod => mod[(process.env.AOT ? 'OrganizationModuleNgFactory' : 'OrganizationModule')]); |
23 | 23 |
} |
24 | 24 |
export function getDepositDatasetsModule() { |
25 |
return System.import('./deposit/depositDatasets.module' + (process.env.AOT ? '.ngfactory' : '')) |
|
25 |
return System.import('./deposit/datasets/depositDatasets.module' + (process.env.AOT ? '.ngfactory' : ''))
|
|
26 | 26 |
.then(mod => mod[(process.env.AOT ? 'DepositDatasetsModuleNgFactory' : 'DepositDatasetsModule')]); |
27 | 27 |
} |
28 | 28 |
export function getDepositDatasetsResultsModule() { |
29 |
return System.import('./deposit/depositDatasetsResults.module' + (process.env.AOT ? '.ngfactory' : '')) |
|
29 |
return System.import('./deposit/datasets/depositDatasetsResults.module' + (process.env.AOT ? '.ngfactory' : ''))
|
|
30 | 30 |
.then(mod => mod[(process.env.AOT ? 'DepositDatasetsResultsModuleNgFactory' : 'DepositDatasetsResultsModule')]); |
31 | 31 |
} |
32 | 32 |
|
33 | 33 |
export function getDepositPublicationsModule() { |
34 |
return System.import('./deposit/depositPublications.module' + (process.env.AOT ? '.ngfactory' : '')) |
|
34 |
return System.import('./deposit/publications/depositPublications.module' + (process.env.AOT ? '.ngfactory' : ''))
|
|
35 | 35 |
.then(mod => mod[(process.env.AOT ? 'DepositPublicationsModuleNgFactory' : 'DepositPublicationsModule')]); |
36 | 36 |
} |
37 | 37 |
export function getDepositPublicationsResultsModule() { |
38 |
return System.import('./deposit/depositPublicationsResults.module' + (process.env.AOT ? '.ngfactory' : '')) |
|
38 |
return System.import('./deposit/publications/depositPublicationsResults.module' + (process.env.AOT ? '.ngfactory' : ''))
|
|
39 | 39 |
.then(mod => mod[(process.env.AOT ? 'DepositPublicationsResultsModuleNgFactory' : 'DepositPublicationsResultsModule')]); |
40 | 40 |
} |
41 | 41 |
export function getDataProviderModule() { |
modules/uoa-services-portal/branches/lazy-routes/portal-2/package.json | ||
---|---|---|
75 | 75 |
"@types/express": "^4.0.32", |
76 | 76 |
"@types/express-serve-static-core": "^4.0.33", |
77 | 77 |
"@types/hammerjs": "^2.0.32", |
78 |
"@types/memory-cache": "0.0.29", |
|
79 | 78 |
"@types/mime": "0.0.28", |
80 | 79 |
"@types/node": "^6.0.38", |
81 | 80 |
"@types/serve-static": "^1.7.27", |
82 | 81 |
"@types/webfontloader": "^1.6.27", |
83 | 82 |
"@ngtools/webpack": "~1.1.7", |
84 |
"accepts": "^1.3.3", |
|
85 | 83 |
"angular2-template-loader": "^0.4.0", |
86 | 84 |
"awesome-typescript-loader": "^2.2.4", |
87 | 85 |
"cookie-parser": "^1.4.3", |
88 |
"express-interceptor": "^1.2.0", |
|
89 |
"iltorb": "^1.0.13", |
|
90 | 86 |
"imports-loader": "^0.6.5", |
91 | 87 |
"json-loader": "^0.5.4", |
92 |
"memory-cache": "^0.1.6", |
|
93 | 88 |
"nodemon": "^1.10.0", |
94 | 89 |
"raw-loader": "^0.5.1", |
95 | 90 |
"reflect-metadata": "0.1.8", |
... | ... | |
98 | 93 |
"ts-helpers": "^1.1.2", |
99 | 94 |
"ts-node": "^1.3.0", |
100 | 95 |
"typescript": "2.0.2", |
101 |
"uglify-js" : "^2.7.4", |
|
102 | 96 |
"v8-lazy-parse-webpack-plugin": "^0.3.0", |
103 | 97 |
"webpack": "2.1.0-beta.27", |
104 | 98 |
"webpack-bundle-analyzer": "1.4.1", |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/server.aot.ts | ||
---|---|---|
76 | 76 |
app.get('/data.json', serverApi); |
77 | 77 |
app.use('/api', createTodoApi()); |
78 | 78 |
|
79 |
process.on('uncaughtException', function (err) { |
|
80 |
console.error('Catching uncaught errors to avoid process crash', err); |
|
81 |
}); |
|
82 |
|
|
79 | 83 |
function ngApp(req, res) { |
80 |
res.render('index', { |
|
81 |
req, |
|
82 |
res, |
|
83 |
// time: true, // use this to determine what part of your app is slow only in development |
|
84 |
preboot: false, |
|
85 |
baseUrl: '/', |
|
86 |
requestUrl: req.originalUrl, |
|
87 |
originUrl: `http://localhost:${ app.get('port') }` |
|
84 |
|
|
85 |
function onHandleError(parentZoneDelegate, currentZone, targetZone, error) { |
|
86 |
console.warn('Error in SSR, serving for direct CSR'); |
|
87 |
res.sendFile('index.html', {root: './src'}); |
|
88 |
return false; |
|
89 |
} |
|
90 |
|
|
91 |
Zone.current.fork({ name: 'CSR fallback', onHandleError }).run(() => { |
|
92 |
res.render('index', { |
|
93 |
req, |
|
94 |
res, |
|
95 |
// time: true, // use this to determine what part of your app is slow only in development |
|
96 |
preboot: false, |
|
97 |
baseUrl: '/', |
|
98 |
requestUrl: req.originalUrl, |
|
99 |
originUrl: `http://localhost:${ app.get('port') }` |
|
100 |
}); |
|
88 | 101 |
}); |
102 |
|
|
89 | 103 |
} |
90 | 104 |
|
91 | 105 |
/** |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/utils/routerHelper.class.ts | ||
---|---|---|
1 |
|
|
2 |
|
|
3 |
|
|
4 |
export class RouterHelper { |
|
5 |
//Use this class function to create queryParams Objects in format {key1:value1} or {key1:value1,key2:value2,key3:value3,...} for multiple parameters |
|
6 |
// <a [queryParams]="RouterHelper.createQueryParam(filter.filterId,value.id)" routerLinkActive="router-link-active" [routerLink]=baseUrl>Link</a> |
|
7 |
public createQueryParam(key:string,value:string){ |
|
8 |
var obj ={}; |
|
9 |
obj[key]=value; |
|
10 |
return obj; |
|
11 |
|
|
12 |
} |
|
13 |
public createQueryParams(keys:string[],values:string[]){ |
|
14 |
var obj ={}; |
|
15 |
if(!keys || !values || keys.length != values.length){ |
|
16 |
return obj; |
|
17 |
}else{ |
|
18 |
for(var i=0; i< keys.length; i++){ |
|
19 |
obj[keys[i]]=values[i]; |
|
20 |
} |
|
21 |
} |
|
22 |
return obj; |
|
23 |
|
|
24 |
} |
|
25 |
|
|
26 |
|
|
27 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/searchPages/find/search.component.ts | ||
---|---|---|
1 |
import {Component, Input, Output, EventEmitter, ViewChild} from '@angular/core'; |
|
1 |
import {Component, Input, Output, EventEmitter, ViewChild, ChangeDetectionStrategy, ViewEncapsulation} from '@angular/core';
|
|
2 | 2 |
import {Observable} from 'rxjs/Observable'; |
3 | 3 |
import {ActivatedRoute, Router} from '@angular/router'; |
4 | 4 |
import {Location} from '@angular/common'; |
... | ... | |
22 | 22 |
import {SearchFields} from '../../utils/properties/searchFields'; |
23 | 23 |
|
24 | 24 |
@Component({ |
25 |
changeDetection: ChangeDetectionStrategy.Default, |
|
26 |
encapsulation: ViewEncapsulation.Emulated, |
|
25 | 27 |
selector: 'search-find', |
26 | 28 |
template: ` |
27 |
|
|
28 | 29 |
<div class="uk-margin-top"> |
29 | 30 |
<div class="page-header"> |
30 | 31 |
<h1>{{pageTitle}}</h1> |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/searchPages/searchUtils/browseStatistic.component.ts | ||
---|---|---|
9 | 9 |
import {SearchFields} from '../../utils/properties/searchFields'; |
10 | 10 |
import {SearchPageComponent } from '../searchUtils/searchPage.component'; |
11 | 11 |
import {SearchUtilsClass} from '../searchUtils/searchUtils.class'; |
12 |
|
|
12 |
import {RouterHelper} from '../../utils/routerHelper.class'; |
|
13 | 13 |
@Component({ |
14 | 14 |
selector: 'browse-statistic', |
15 | 15 |
template: ` |
... | ... | |
18 | 18 |
<h4 class="tm-article-subtitle">{{filter.title}}</h4> |
19 | 19 |
<div *ngIf="filter.values.length == 0" class="uk-alert uk-alert-info" role="alert">No {{filter.title}} statistics found</div> |
20 | 20 |
<ul *ngIf="filter.values.length > 0 && !viewAll" class="uk-list uk-list-line "> |
21 |
<li *ngFor= "let value of filter.values.slice(0,5)"><a [href]="baseUrl+'?'+filter.filterId+'='+value.id">{{_formatName(value)}} ({{value.number}})</a></li> |
|
21 |
<li *ngFor= "let value of filter.values.slice(0,5)"><!--a [href]="baseUrl+'?'+filter.filterId+'='+value.id">{{_formatName(value)}} ({{value.number}})</a--> |
|
22 |
<a [queryParams]="routerHelper.createQueryParam(filter.filterId,value.id)" routerLinkActive="router-link-active" [routerLink]=baseUrl>{{_formatName(value)}} ({{value.number}})</a> |
|
23 |
</li> |
|
22 | 24 |
<li *ngIf= " filter.values.length > 5 && !viewAll " (click)="viewAll=true;"> |
23 | 25 |
<span ><span class="uk-text-muted clickable">View more </span><a><i class="uk-icon-toggle-right"></i></a></span> |
24 | 26 |
</li> |
25 | 27 |
</ul> |
26 | 28 |
<ul *ngIf="filter.values.length > 0 && viewAll" class="uk-list uk-list-line searchFilterBoxValues"> |
27 |
<li *ngFor= "let value of filter.values"><a [href]="baseUrl+'?'+filter.filterId+'='+value.id">{{_formatName(value)}} ({{value.number}})</a></li> |
|
29 |
<li *ngFor= "let value of filter.values"><!--a [href]="baseUrl+'?'+filter.filterId+'='+value.id">{{_formatName(value)}} ({{value.number}})</a--> |
|
30 |
<a [queryParams]="routerHelper.createQueryParam(filter.filterId,value.id)" routerLinkActive="router-link-active" [routerLink]=baseUrl>{{_formatName(value)}} ({{value.number}})</a> |
|
31 |
</li> |
|
28 | 32 |
<li *ngIf= " filter.values.length > 5 && viewAll " (click)="viewAll=false;"> |
29 | 33 |
<span ><span class="uk-text-muted clickable">View less </span><a><i class="uk-icon-toggle-up"></i></a></span> |
30 | 34 |
</li> |
31 | 35 |
</ul> |
32 | 36 |
|
33 |
|
|
34 |
|
|
35 | 37 |
` |
36 | 38 |
|
37 | 39 |
}) |
... | ... | |
41 | 43 |
@Input() public filter:any = ""; |
42 | 44 |
private _maxCharacters = 30; |
43 | 45 |
public viewAll = false; |
44 |
|
|
46 |
public routerHelper:RouterHelper = new RouterHelper(); |
|
45 | 47 |
constructor () { |
46 | 48 |
|
47 | 49 |
} |
... | ... | |
51 | 53 |
|
52 | 54 |
} |
53 | 55 |
|
56 |
|
|
54 | 57 |
private _formatName(value){ |
55 | 58 |
return (((value.name+" ("+value.number+")").length >this._maxCharacters)?(value.name.substring(0,(this._maxCharacters - (" ("+value.number+")").length - ('...').length))+"..."):value.name) |
56 | 59 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/searchPages/searchUtils/browseEntities.module.ts | ||
---|---|---|
1 | 1 |
import { NgModule} from '@angular/core'; |
2 | 2 |
import { CommonModule } from '@angular/common'; |
3 | 3 |
import { FormsModule } from '@angular/forms'; |
4 |
import { RouterModule } from '@angular/router'; |
|
4 | 5 |
|
5 | 6 |
import {RefineFieldResultsServiceModule} from '../../services/refineFieldResultsService.module'; |
6 | 7 |
|
... | ... | |
11 | 12 |
@NgModule({ |
12 | 13 |
imports: [ |
13 | 14 |
CommonModule, FormsModule, |
14 |
RefineFieldResultsServiceModule |
|
15 |
RefineFieldResultsServiceModule, RouterModule
|
|
15 | 16 |
], |
16 | 17 |
declarations: [ |
17 | 18 |
BrowseEntitiesComponent, |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/datasets/depositDatasetsResults-routing.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { RouterModule } from '@angular/router'; |
|
3 |
|
|
4 |
import { DepositDatasetsResultComponent } from './depositDatasetsResult.component'; |
|
5 |
|
|
6 |
@NgModule({ |
|
7 |
imports: [ |
|
8 |
RouterModule.forChild([ |
|
9 |
{ path: '', component: DepositDatasetsResultComponent } |
|
10 |
|
|
11 |
]) |
|
12 |
] |
|
13 |
}) |
|
14 |
export class DepositDatasetsResultsRoutingModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/datasets/depositDatasetsResult.component.ts | ||
---|---|---|
1 |
import {Component} from '@angular/core'; |
|
2 |
|
|
3 |
@Component({ |
|
4 |
selector: 'deposit-datasets-result', |
|
5 |
template: ` |
|
6 |
<deposit-result [compatibility]="'Registry of Research Data Repository'" [requestFor]="'Research Data'"></deposit-result> |
|
7 |
` |
|
8 |
}) |
|
9 |
|
|
10 |
export class DepositDatasetsResultComponent { |
|
11 |
|
|
12 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/datasets/depositDatasets.component.ts | ||
---|---|---|
1 |
import {Component} from '@angular/core'; |
|
2 |
|
|
3 |
@Component({ |
|
4 |
selector: 'deposit-datasets', |
|
5 |
template: ` |
|
6 |
<deposit [compatibility]="'Registry of Research Data Repository'" [requestFor]="'Research Data'"></deposit> |
|
7 |
` |
|
8 |
}) |
|
9 |
|
|
10 |
export class DepositDatasetsComponent { |
|
11 |
|
|
12 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/datasets/depositDatasets.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { CommonModule } from '@angular/common'; |
|
3 |
import { FormsModule } from '@angular/forms'; |
|
4 |
|
|
5 |
import { DepositDatasetsComponent } from './depositDatasets.component'; |
|
6 |
import { DepositDatasetsResultComponent } from './depositDatasetsResult.component'; |
|
7 |
|
|
8 |
import {DepositDatasetsRoutingModule} from './depositDatasets-routing.module'; |
|
9 |
import {DepoditModule} from '../deposit.module'; |
|
10 |
|
|
11 |
@NgModule({ |
|
12 |
imports: [ |
|
13 |
CommonModule, FormsModule, |
|
14 |
DepoditModule, |
|
15 |
DepositDatasetsRoutingModule |
|
16 |
], |
|
17 |
declarations: [ |
|
18 |
|
|
19 |
DepositDatasetsComponent, |
|
20 |
|
|
21 |
], |
|
22 |
exports: [ |
|
23 |
DepositDatasetsComponent, |
|
24 |
], |
|
25 |
providers: [ |
|
26 |
] |
|
27 |
}) |
|
28 |
export class DepositDatasetsModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/datasets/depositDatasetsResults.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { CommonModule } from '@angular/common'; |
|
3 |
import { FormsModule } from '@angular/forms'; |
|
4 |
|
|
5 |
import { DepositDatasetsResultComponent } from './depositDatasetsResult.component'; |
|
6 |
|
|
7 |
import {DepositDatasetsResultsRoutingModule} from './depositDatasetsResults-routing.module'; |
|
8 |
import {DepoditModule} from '../deposit.module'; |
|
9 |
|
|
10 |
@NgModule({ |
|
11 |
imports: [ |
|
12 |
CommonModule, FormsModule, |
|
13 |
DepoditModule, |
|
14 |
DepositDatasetsResultsRoutingModule |
|
15 |
], |
|
16 |
declarations: [ |
|
17 |
|
|
18 |
DepositDatasetsResultComponent, |
|
19 |
|
|
20 |
], |
|
21 |
exports: [ |
|
22 |
DepositDatasetsResultComponent, |
|
23 |
], |
|
24 |
providers: [ |
|
25 |
] |
|
26 |
}) |
|
27 |
export class DepositDatasetsResultsModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/datasets/depositDatasets-routing.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { RouterModule } from '@angular/router'; |
|
3 |
|
|
4 |
import { DepositDatasetsComponent } from './depositDatasets.component'; |
|
5 |
import { DepositDatasetsResultComponent } from './depositDatasetsResult.component'; |
|
6 |
|
|
7 |
@NgModule({ |
|
8 |
imports: [ |
|
9 |
RouterModule.forChild([ |
|
10 |
{ path: '', component: DepositDatasetsComponent } |
|
11 |
|
|
12 |
]) |
|
13 |
] |
|
14 |
}) |
|
15 |
export class DepositDatasetsRoutingModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/publications/depositPublicationsResults.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { CommonModule } from '@angular/common'; |
|
3 |
import { FormsModule } from '@angular/forms'; |
|
4 |
|
|
5 |
import { DepositPublicationsResultComponent } from './depositPublicationsResult.component'; |
|
6 |
|
|
7 |
import {DepositPublicationsResultRoutingModule} from './depositPublicationsResult-routing.module'; |
|
8 |
import {DepoditModule} from '../deposit.module'; |
|
9 |
|
|
10 |
@NgModule({ |
|
11 |
imports: [ |
|
12 |
CommonModule, FormsModule, |
|
13 |
DepoditModule, |
|
14 |
DepositPublicationsResultRoutingModule |
|
15 |
], |
|
16 |
declarations: [ |
|
17 |
|
|
18 |
DepositPublicationsResultComponent, |
|
19 |
|
|
20 |
], |
|
21 |
exports: [ |
|
22 |
DepositPublicationsResultComponent, |
|
23 |
], |
|
24 |
providers: [ |
|
25 |
] |
|
26 |
}) |
|
27 |
export class DepositPublicationsResultsModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/publications/depositPublicationsResult-routing.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { RouterModule } from '@angular/router'; |
|
3 |
|
|
4 |
import { DepositPublicationsResultComponent } from './depositPublicationsResult.component'; |
|
5 |
|
|
6 |
@NgModule({ |
|
7 |
imports: [ |
|
8 |
RouterModule.forChild([ |
|
9 |
{ path: '', component: DepositPublicationsResultComponent } |
|
10 |
|
|
11 |
]) |
|
12 |
] |
|
13 |
}) |
|
14 |
export class DepositPublicationsResultRoutingModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/publications/depositPublications-routing.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { RouterModule } from '@angular/router'; |
|
3 |
|
|
4 |
import { DepositPublicationsComponent } from './depositPublications.component'; |
|
5 |
|
|
6 |
@NgModule({ |
|
7 |
imports: [ |
|
8 |
RouterModule.forChild([ |
|
9 |
{ path: '', component: DepositPublicationsComponent } |
|
10 |
|
|
11 |
]) |
|
12 |
] |
|
13 |
}) |
|
14 |
export class DepositPublicationsRoutingModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/publications/depositPublicationsResult.component.ts | ||
---|---|---|
1 |
import {Component} from '@angular/core'; |
|
2 |
|
|
3 |
@Component({ |
|
4 |
selector: 'deposit-publications-result', |
|
5 |
template: ` |
|
6 |
<deposit-result [compatibility]="'OpenDOAR'" [requestFor]="'Publications'"></deposit-result> |
|
7 |
` |
|
8 |
}) |
|
9 |
|
|
10 |
export class DepositPublicationsResultComponent { |
|
11 |
|
|
12 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/publications/depositPublications.component.ts | ||
---|---|---|
1 |
import {Component} from '@angular/core'; |
|
2 |
|
|
3 |
@Component({ |
|
4 |
selector: 'deposit-publications', |
|
5 |
template: ` |
|
6 |
<deposit [compatibility]="'OpenDOAR'" [requestFor]="'Publications'"></deposit> |
|
7 |
<h3>Or locate data provider in map</h3> |
|
8 |
<div class="uk-margin-top"> |
|
9 |
<i-frame [url]="mapUrl"width="100%" height="900"></i-frame> |
|
10 |
</div> |
|
11 |
` |
|
12 |
}) |
|
13 |
|
|
14 |
export class DepositPublicationsComponent { |
|
15 |
public mapUrl ="https://beta.openaire.eu/stats/markers-demo.html"; |
|
16 |
} |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/deposit/publications/depositPublications.module.ts | ||
---|---|---|
1 |
import { NgModule } from '@angular/core'; |
|
2 |
import { CommonModule } from '@angular/common'; |
|
3 |
import { FormsModule } from '@angular/forms'; |
|
4 |
|
|
5 |
import { DepositPublicationsComponent } from './depositPublications.component'; |
|
6 |
|
|
7 |
import {DepositPublicationsRoutingModule} from './depositPublications-routing.module'; |
|
8 |
import {DepoditModule} from '../deposit.module'; |
|
9 |
import {IFrameModule} from '../../utils/iframe.module'; |
|
10 |
|
|
11 |
@NgModule({ |
|
12 |
imports: [ |
|
13 |
CommonModule, FormsModule, |
|
14 |
DepoditModule, |
|
15 |
DepositPublicationsRoutingModule,IFrameModule |
|
16 |
], |
|
17 |
declarations: [ |
|
18 |
|
|
19 |
DepositPublicationsComponent, |
|
20 |
|
|
21 |
], |
|
22 |
exports: [ |
|
23 |
DepositPublicationsComponent, |
|
24 |
], |
|
25 |
providers: [ |
|
26 |
] |
|
27 |
}) |
|
28 |
export class DepositPublicationsModule { } |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/app.module.ts | ||
---|---|---|
1 |
//import {MaterialModule} from '@angular/material'; |
|
2 | 1 |
import { NgModule } from '@angular/core'; |
3 | 2 |
import { FormsModule } from '@angular/forms'; |
4 | 3 |
|
... | ... | |
9 | 8 |
import { AppComponent, XLargeDirective } from './app.component'; |
10 | 9 |
|
11 | 10 |
import {SharedComponentsModule} from './sharedComponents/sharedComponents.module'; //navbar |
12 |
|
|
13 | 11 |
import { ErrorModule } from './error/error.module'; |
14 | 12 |
import { CacheService } from './shared/cache.service'; |
15 | 13 |
|
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/landingPages/resultLanding.module.ts | ||
---|---|---|
2 | 2 |
import { NgModule} from '@angular/core'; |
3 | 3 |
import { CommonModule } from '@angular/common'; |
4 | 4 |
import { FormsModule } from '@angular/forms'; |
5 |
import { RouterModule } from '@angular/router'; |
|
5 | 6 |
|
6 | 7 |
import {ShowAuthorsComponent} from './showAuthors.component'; |
7 | 8 |
import {ShowIdentifiersComponent} from './showIdentifiers.component'; |
... | ... | |
10 | 11 |
|
11 | 12 |
@NgModule({ |
12 | 13 |
imports: [ |
13 |
CommonModule, FormsModule, |
|
14 |
CommonModule, FormsModule, RouterModule
|
|
14 | 15 |
], |
15 | 16 |
declarations: [ |
16 | 17 |
ShowAuthorsComponent,ShowIdentifiersComponent,ShowSubjectsComponent |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/landingPages/dataset/dataset.component.html | ||
---|---|---|
1 | 1 |
<div class="uk-container uk-margin-top dataset"> |
2 | 2 |
<!--div class="container-header" --> |
3 |
|
|
3 |
|
|
4 | 4 |
<div *ngIf="warningMessage.length > 0" class="uk-alert uk-alert-warning" role="alert">{{warningMessage}}</div> |
5 | 5 |
<div *ngIf="errorMessage.length > 0" class="uk-alert uk-alert-danger" role="alert">{{errorMessage}}</div> |
6 | 6 |
|
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/landingPages/dataset/dataset.module.ts | ||
---|---|---|
2 | 2 |
import { NgModule} from '@angular/core'; |
3 | 3 |
import { CommonModule } from '@angular/common'; |
4 | 4 |
import { FormsModule } from '@angular/forms'; |
5 |
import { SharedModule } from '../../shared/shared.module'; |
|
5 | 6 |
|
6 | 7 |
import { DatasetService} from './dataset.service'; |
7 | 8 |
import { DatasetComponent } from './dataset.component'; |
... | ... | |
15 | 16 |
@NgModule({ |
16 | 17 |
imports: [ |
17 | 18 |
//MaterialModule.forRoot(), |
18 |
CommonModule, FormsModule, LandingModule, |
|
19 |
CommonModule, FormsModule,SharedModule, LandingModule,
|
|
19 | 20 |
ResultLandingModule, DatasetRoutingModule, MetricsModule, IFrameModule |
20 | 21 |
], |
21 | 22 |
declarations: [ |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/landingPages/person/person.module.ts | ||
---|---|---|
8 | 8 |
|
9 | 9 |
import { LandingModule } from '../landing.module'; |
10 | 10 |
import {SearchResultsModule } from '../../searchPages/searchUtils/searchResults.module'; |
11 |
import {DatasetsServiceModule} from '../../services/datasetsService.module'; |
|
12 |
import {PublicationsServiceModule} from '../../services/publicationsService.module'; |
|
13 |
|
|
11 | 14 |
@NgModule({ |
12 | 15 |
imports: [ |
13 | 16 |
CommonModule, FormsModule, |
14 | 17 |
LandingModule, |
15 | 18 |
PersonRoutingModule, |
16 |
SearchResultsModule |
|
19 |
SearchResultsModule, |
|
20 |
DatasetsServiceModule, PublicationsServiceModule |
|
17 | 21 |
], |
18 | 22 |
declarations: [ |
19 | 23 |
PersonComponent |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/landingPages/publication/publication.module.ts | ||
---|---|---|
2 | 2 |
import { NgModule} from '@angular/core'; |
3 | 3 |
import { CommonModule } from '@angular/common'; |
4 | 4 |
import { FormsModule } from '@angular/forms'; |
5 |
import { SharedModule } from '../../shared/shared.module'; |
|
5 | 6 |
|
6 | 7 |
import { PublicationService} from './publication.service'; |
7 | 8 |
import { PublicationComponent } from './publication.component'; |
... | ... | |
16 | 17 |
|
17 | 18 |
@NgModule({ |
18 | 19 |
imports: [ |
19 |
CommonModule, FormsModule, LandingModule, |
|
20 |
CommonModule, FormsModule, LandingModule,SharedModule,
|
|
20 | 21 |
ResultLandingModule, PublicationRoutingModule, MetricsModule, IFrameModule, AltMetricsModule |
21 | 22 |
], |
22 | 23 |
declarations: [ |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/landingPages/showAuthors.component.ts | ||
---|---|---|
8 | 8 |
<a class="uk-text-muted" (click)="showAll = !showAll;">View less authors</a> |
9 | 9 |
</div> |
10 | 10 |
<span *ngFor="let item of authors.slice(0,30)"> |
11 |
<a href="{{item['url']}}"> |
|
11 |
<a href="{{item['url']}}"> |
|
12 |
<!--a routerLinkActive="router-link-active" routerLink="/search/person" [queryParams]="{personId: 'datacite____::9da3a037961b36a634fcd40ab0bf6535'}" --> |
|
12 | 13 |
{{item['name']}}; |
13 | 14 |
</a> |
14 | 15 |
</span> |
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/app/sharedComponents/navigationBar.component.ts | ||
---|---|---|
5 | 5 |
selector: 'navbar', |
6 | 6 |
template: ` |
7 | 7 |
|
8 |
|
|
9 |
|
|
10 |
|
|
11 |
|
|
12 |
|
|
13 |
|
|
14 | 8 |
<nav class="uk-navbar"> |
15 | 9 |
|
16 | 10 |
<ul class="uk-navbar-nav uk-hidden-small"> |
17 |
<li class="uk-active"><a href="/" class="uk-logo uk-navbar-item">
|
|
11 |
<li class="uk-active"><a routerLinkActive="router-link-active" routerLink="" class="uk-logo uk-navbar-item">
|
|
18 | 12 |
<img src="assets/newlogo.png" alt="OpenAIRE" class="uk-responsive-height"></a> |
19 | 13 |
</li> |
20 |
<li class="uk-active"><a href="/search/find"><i class="uk-icon-home"></i></a></li>
|
|
14 |
<li class="uk-active"><a routerLinkActive="router-link-active" routerLink="search/find"><i class="uk-icon-home"></i></a></li>
|
|
21 | 15 |
<li class="uk-parent" data-uk-dropdown="" aria-haspopup="true" aria-expanded="false"> |
22 |
<a href="/search/find">Search</a>
|
|
16 |
<a routerLinkActive="router-link-active" routerLink="search/find">Search</a>
|
|
23 | 17 |
|
24 | 18 |
<div class="uk-dropdown uk-dropdown-navbar uk-dropdown-bottom" aria-hidden="true" style="top: 40px; left: 0px;" tabindex=""> |
25 | 19 |
<ul class="uk-nav uk-nav-navbar"> |
26 | 20 |
<!--li class="uk-nav-header">Search For</li--> |
27 |
<li><a href="/search/find/publications">Publications</a></li> |
|
28 |
<li><a href="/search/find/datasets">Datasets</a></li> |
|
29 |
<li><a href="/search/find/projects">Projects</a></li> |
|
30 |
<li><a href="/search/find/dataproviders">Data Providers</a></li> |
|
31 |
<li><a href="/search/find/organizations">Organizations</a></li> |
|
32 |
<li><a href="/search/find/people">People</a></li> |
|
33 |
<!--li class="uk-nav-divider"></li> |
|
34 |
<li class="uk-nav-header">Data Providers</li> |
|
35 |
<li><a href="/search/data-providers">Compatible Data Providers</a></li> |
|
36 |
<li><a href="/search/entity-registries">Entity Registries</a></li--> |
|
21 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/publications">Publications</a></li> |
|
22 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/datasets">Datasets</a></li> |
|
23 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/projects">Projects</a></li> |
|
24 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/dataproviders">Data Providers</a></li> |
|
25 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/organizations">Organizations</a></li> |
|
26 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/people">People</a></li> |
|
27 |
<li class="uk-nav-divider"></li> |
|
28 |
<li><a [queryParams]="{articleId: 'od_______908::3a5b2885656a91307156325644e73b92'}" routerLinkActive="router-link-active" routerLink="search/publication" >Publication </a></li> |
|
29 |
<li><a [queryParams]="{datasetId: 'datacite____::430ac1c41b7f99b7b543ef737dc41a74'}" routerLinkActive="router-link-active" routerLink="search/dataset" >Dataset </a></li> |
|
30 |
<li><a [queryParams]="{projectId: 'corda_______::2c37878a0cede85dbbd1081bb9b4a2f8'}" routerLinkActive="router-link-active" routerLink="search/project" >Project </a></li> |
|
31 |
<li><a [queryParams]="{personId: 'datacite____::9da3a037961b36a634fcd40ab0bf6535'}" routerLinkActive="router-link-active" routerLink="search/person" >Person </a></li> |
|
32 |
<li><a [queryParams]="{organizationId: 'dedup_wf_001::f686277c34bf457bbdf19e03589b5e81'}" routerLinkActive="router-link-active" routerLink="search/organization" >Organization </a></li> |
|
33 |
<li><a [queryParams]="{datasourceId: 'opendoar____::798ed7d4ee7138d49b8828958048130a'}" routerLinkActive="router-link-active" routerLink="search/dataprovider" >Data Provider </a></li> |
|
34 |
|
|
37 | 35 |
</ul> |
38 | 36 |
</div> |
39 | 37 |
|
40 | 38 |
</li> |
41 | 39 |
<li class="uk-parent" data-uk-dropdown="" aria-haspopup="true" aria-expanded="false"> |
42 |
<a href="/search/data-providers" >Data Providers</a>
|
|
40 |
<a routerLinkActive="router-link-active" routerLink="search/data-providers" >Data Providers</a>
|
|
43 | 41 |
|
44 | 42 |
<div class="uk-dropdown uk-dropdown-navbar uk-dropdown-bottom" aria-hidden="true" style="top: 40px; left: 0px;" tabindex=""> |
45 | 43 |
<ul class="uk-nav uk-nav-navbar"> |
46 | 44 |
<!--li class="uk-nav-header">Search for Data Providers</li--> |
47 |
<li><a href="/search/data-providers">Compatible Data Providers</a></li>
|
|
48 |
<li><a href="/search/entity-registries">Entity Registries</a></li>
|
|
45 |
<li><a routerLinkActive="router-link-active" routerLink="search/data-providers">Compatible Data Providers</a></li>
|
|
46 |
<li><a routerLinkActive="router-link-active" routerLink="search/entity-registries">Entity Registries</a></li>
|
|
49 | 47 |
</ul> |
50 | 48 |
</div> |
51 | 49 |
|
52 | 50 |
</li> |
53 | 51 |
<li class="uk-parent" data-uk-dropdown="" aria-haspopup="true" aria-expanded="false"> |
54 |
<a href="/search/advanced/publications">Advanced Search</a>
|
|
52 |
<a routerLinkActive="router-link-active" routerLink="search/advanced/publications">Advanced Search</a>
|
|
55 | 53 |
|
56 | 54 |
<div class="uk-dropdown uk-dropdown-navbar uk-dropdown-bottom" aria-hidden="true" style="top: 40px; left: 0px;" tabindex=""> |
57 | 55 |
<ul class="uk-nav uk-nav-navbar"> |
58 |
<li><a href="/search/advanced/publications">Advanced Search Publications</a></li>
|
|
59 |
<li><a href="/search/advanced/datasets">Advanced Search Research Data</a></li>
|
|
60 |
<li><a href="/search/advanced/projects">Advanced Search Projects</a></li>
|
|
61 |
<li><a href="/search/advanced/dataproviders">Advanced Search Data Providers</a></li>
|
|
62 |
<li><a href="/search/advanced/organizations">Advanced Search Organizations</a></li>
|
|
63 |
<li><a href="/search/advanced/people">Advanced Search People</a></li>
|
|
56 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/publications">Advanced Search Publications</a></li>
|
|
57 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/datasets">Advanced Search Research Data</a></li>
|
|
58 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/projects">Advanced Search Projects</a></li>
|
|
59 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/dataproviders">Advanced Search Data Providers</a></li>
|
|
60 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/organizations">Advanced Search Organizations</a></li>
|
|
61 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/people">Advanced Search People</a></li>
|
|
64 | 62 |
</ul> |
65 | 63 |
</div> |
66 | 64 |
|
67 | 65 |
</li> |
68 | 66 |
<li class="uk-parent" data-uk-dropdown="" aria-haspopup="true" aria-expanded="false"> |
69 |
<a href="/deposit-publications" >Deposit</a>
|
|
67 |
<a routerLinkActive="router-link-active" routerLink="deposit-publications" >Deposit</a>
|
|
70 | 68 |
|
71 | 69 |
<div class="uk-dropdown uk-dropdown-navbar uk-dropdown-bottom" aria-hidden="true" style="top: 40px; left: 0px;" tabindex=""> |
72 | 70 |
<ul class="uk-nav uk-nav-navbar"> |
73 |
<li><a href="/deposit-publications">Deposit Publications</a></li>
|
|
74 |
<li><a href="/deposit-datasets">Deposit Research Data</a></li>
|
|
71 |
<li><a routerLinkActive="router-link-active" routerLink="deposit-publications">Deposit Publications</a></li>
|
|
72 |
<li><a routerLinkActive="router-link-active" routerLink="deposit-datasets">Deposit Research Data</a></li>
|
|
75 | 73 |
</ul> |
76 | 74 |
</div> |
77 | 75 |
|
78 | 76 |
</li> |
79 |
|
|
77 |
|
|
80 | 78 |
</ul> |
81 | 79 |
|
82 | 80 |
<a href="#offcanvas-mainmenu" class="uk-navbar-toggle uk-visible-small" data-uk-offcanvas="{mode:'slide'}"></a> |
... | ... | |
92 | 90 |
<div class="uk-offcanvas-bar uk-offcanvas-bar-show" mode="push"> |
93 | 91 |
<!--ul class="uk-navbar-nav uk-hidden-small"--> |
94 | 92 |
<ul class="uk-nav uk-nav-offcanvas uk-nav-parent-icon" data-uk-nav="{multiple:true}"> |
95 |
<!--li class="uk-active"><a href="/" class="uk-logo uk-navbar-item">
|
|
93 |
<!--li class="uk-active"><a routerLinkActive="router-link-active" routerLink="" class="uk-logo uk-navbar-item">
|
|
96 | 94 |
<img src="assets/newlogo.png" alt="OpenAIRE" class="uk-responsive-height"></a> |
97 | 95 |
</li--> |
98 |
<li class="uk-active"><a href="/search/find"><i class="uk-icon-home"></i></a></li>
|
|
96 |
<li class="uk-active"><a routerLinkActive="router-link-active" routerLink="search/find"><i class="uk-icon-home"></i></a></li>
|
|
99 | 97 |
|
100 | 98 |
<li class="" aria-expanded="false" > |
101 | 99 |
<a href="#">Search</a> |
102 | 100 |
|
103 | 101 |
<div ><ul class="uk-nav-sub" role="menu"> |
104 |
<li><a href="/search/find/publications">Publications</a></li>
|
|
105 |
<li><a href="/search/find/datasets">Datasets</a></li>
|
|
106 |
<li><a href="/search/find/projects">Projects</a></li>
|
|
107 |
<li><a href="/search/find/dataproviders">Data Providers</a></li>
|
|
108 |
<li><a href="/search/find/organizations">Organizations</a></li>
|
|
109 |
<li><a href="/search/find/people">People</a></li>
|
|
102 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/publications">Publications</a></li>
|
|
103 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/datasets">Datasets</a></li>
|
|
104 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/projects">Projects</a></li>
|
|
105 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/dataproviders">Data Providers</a></li>
|
|
106 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/organizations">Organizations</a></li>
|
|
107 |
<li><a routerLinkActive="router-link-active" routerLink="search/find/people">People</a></li>
|
|
110 | 108 |
</ul> |
111 | 109 |
</div> |
112 | 110 |
|
... | ... | |
115 | 113 |
<a href="#">Data Providers</a> |
116 | 114 |
|
117 | 115 |
<div ><ul class="uk-nav-sub" role="menu"> |
118 |
<li><a href="/search/data-providers">Compatible Data Providers</a></li>
|
|
119 |
<li><a href="/search/entity-registries">Entity Registries</a></li>
|
|
116 |
<li><a routerLinkActive="router-link-active" routerLink="search/data-providers">Compatible Data Providers</a></li>
|
|
117 |
<li><a routerLinkActive="router-link-active" routerLink="search/entity-registries">Entity Registries</a></li>
|
|
120 | 118 |
</ul> |
121 | 119 |
</div> |
122 | 120 |
|
... | ... | |
125 | 123 |
<a href="#">Advanced Search</a> |
126 | 124 |
|
127 | 125 |
<div ><ul class="uk-nav-sub" role="menu"> |
128 |
<li><a href="/search/advanced/publications">Advanced Search Publications</a></li>
|
|
129 |
<li><a href="/search/advanced/datasets">Advanced Search Research Data</a></li>
|
|
130 |
<li><a href="/search/advanced/projects">Advanced Search Projects</a></li>
|
|
131 |
<li><a href="/search/advanced/dataproviders">Advanced Search Data Providers</a></li>
|
|
132 |
<li><a href="/search/advanced/organizations">Advanced Search Organizations</a></li>
|
|
133 |
<li><a href="/search/advanced/people">Advanced Search People</a></li>
|
|
126 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/publications">Advanced Search Publications</a></li>
|
|
127 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/datasets">Advanced Search Research Data</a></li>
|
|
128 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/projects">Advanced Search Projects</a></li>
|
|
129 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/dataproviders">Advanced Search Data Providers</a></li>
|
|
130 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/organizations">Advanced Search Organizations</a></li>
|
|
131 |
<li><a routerLinkActive="router-link-active" routerLink="search/advanced/people">Advanced Search People</a></li>
|
|
134 | 132 |
</ul> |
135 | 133 |
</div> |
136 | 134 |
|
... | ... | |
140 | 138 |
<a href="#">Deposit</a> |
141 | 139 |
|
142 | 140 |
<div ><ul class="uk-nav-sub" role="menu"> |
143 |
<li><a href="/deposit-publications">Deposit Publications</a></li>
|
|
144 |
<li><a href="/deposit-datasets">Deposit Research Data</a></li>
|
|
141 |
<li><a routerLinkActive="router-link-active" routerLink="deposit-publications">Deposit Publications</a></li>
|
|
142 |
<li><a routerLinkActive="router-link-active" routerLink="deposit-datasets">Deposit Research Data</a></li>
|
|
145 | 143 |
</ul> |
146 | 144 |
</div> |
147 | 145 |
|
modules/uoa-services-portal/branches/lazy-routes/portal-2/src/server.ts | ||
---|---|---|
69 | 69 |
app.get('/data.json', serverApi); |
70 | 70 |
app.use('/api', createTodoApi()); |
71 | 71 |
|
72 |
process.on('uncaughtException', function (err) { |
|
73 |
console.error('Catching uncaught errors to avoid process crash', err); |
|
74 |
}); |
|
75 |
|
|
72 | 76 |
function ngApp(req, res) { |
73 |
res.render('index', { |
|
74 |
req, |
|
75 |
res, |
|
76 |
// time: true, // use this to determine what part of your app is slow only in development |
|
77 |
preboot: false, |
|
78 |
baseUrl: '/', |
|
79 |
requestUrl: req.originalUrl, |
|
80 |
originUrl: `http://localhost:${ app.get('port') }` |
|
77 |
|
|
78 |
function onHandleError(parentZoneDelegate, currentZone, targetZone, error) { |
|
79 |
console.warn('Error in SSR, serving for direct CSR'); |
|
80 |
res.sendFile('index.html', {root: './src'}); |
|
81 |
return false; |
|
82 |
} |
|
83 |
|
|
84 |
Zone.current.fork({ name: 'CSR fallback', onHandleError }).run(() => { |
|
85 |
res.render('index', { |
|
86 |
req, |
|
87 |
res, |
|
88 |
// time: true, // use this to determine what part of your app is slow only in development |
|
89 |
preboot: false, |
|
90 |
baseUrl: '/', |
|
91 |
requestUrl: req.originalUrl, |
|
92 |
originUrl: `http://localhost:${ app.get('port') }` |
|
93 |
}); |
|
81 | 94 |
}); |
95 |
|
|
82 | 96 |
} |
83 | 97 |
|
84 | 98 |
/** |
modules/uoa-services-portal/branches/lazy-routes/portal-2/README.md | ||
---|---|---|
53 | 53 |
} |
54 | 54 |
``` |
55 | 55 |
- The application runs XHR requests on the server & once again on the Client-side (when the application bootstraps) |
56 |
- Use a [UniversalCache](https://github.com/angular/universal-starter/blob/master/src/+app/shared/api.service.ts#L47-L71) instead of regular Http, to save certain requests so they aren't re-ran again on the Client.
|
|
56 |
- Use a [UniversalCache](https://github.com/angular/universal-starter/blob/master/src/%2Bapp/shared/model/model.service.ts#L34-L50) instead of regular Http, to save certain requests so they aren't re-ran again on the Client. ([Example useage here](https://github.com/angular/universal-starter/blob/cc71e2d5b2d783f2bb52eebd1b5c6fa0ba23f08a/src/%2Bapp/%2Bhome/home.component.ts#L22-L24))
|
|
57 | 57 |
- Know the difference between attributes and properties in relation to the DOM. |
58 | 58 |
- Keep your directives stateless as much as possible. For stateful directives, you may need to provide an attribute that reflects the corresponding property with an initial string value such as url in img tag. For our native `<img src="">` element the src attribute is reflected as the src property of the element type HTMLImageElement. |
59 | 59 |
|
60 | 60 |
### Brotli Compression Support |
61 | 61 |
|
62 |
To enable Brotli compression for server response with fallback for gzip replace the following code from src/server.aot.ts |
|
63 |
|
|
62 |
To enable Brotli compression for server response with fallback for gzip. Install the following packages |
|
64 | 63 |
``` |
64 |
npm install --save-dev iltorb accepts @types/accepts express-interceptor memory-cache @types/memory-cache |
|
65 |
``` |
|
66 |
and replace the following code from src/server.aot.ts. |
|
67 |
``` |
|
65 | 68 |
import * as compression from 'compression'; |
66 | 69 |
|
67 | 70 |
app.use(compression()); |
... | ... | |
99 | 102 |
} |
100 | 103 |
} else { |
101 | 104 |
const { output, encoding } = mcache.get(key); |
102 |
res.setHeader('Content-Encoding', encoding); |
|
103 |
send(output); |
|
105 |
if(encodings.has(encoding)){ |
|
106 |
res.setHeader('Content-Encoding', encoding); |
|
107 |
send(output); |
|
108 |
return; |
|
109 |
} |
|
104 | 110 |
} |
105 | 111 |
send(output); |
106 | 112 |
} |
Also available in: Unified diff
Update to the lattest version of Angular Universal | create subfolders for deposit | use routerLinks in Nav bar and in browse view of main search