diff --git a/portal-2/src/app/searchPages/find/search.component.ts b/portal-2/src/app/searchPages/find/search.component.ts
index cfce9d11..4d70c9c3 100644
--- a/portal-2/src/app/searchPages/find/search.component.ts
+++ b/portal-2/src/app/searchPages/find/search.component.ts
@@ -28,216 +28,7 @@ import {PiwikService} from '../../utils/piwik/piwik.service';
changeDetection: ChangeDetectionStrategy.Default,
encapsulation: ViewEncapsulation.Emulated,
selector: 'search-find',
- template: `
-
-
-
-
-
-
-
-
-
-
-
-
- {{activeTab}}
-
-
-
-
-
-
-
-
-
0 && activeTab=='publications'" class ="uk-animation-fade">
-
-
-
-
-
-
-
-
-
-
-
0 && activeTab=='research data'" class ="uk-animation-fade">
-
-
-
-
-
-
-
-
-
-
-
0 && activeTab=='projects'" class ="uk-animation-fade">
-
-
-
-
-
-
-
-
-
-
-
0 && activeTab=='content providers'" class ="uk-animation-fade">
-
-
-
-
-
-
-
-
-
-
-
0" class ="uk-animation-fade">
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- `
+ templateUrl: 'search.component.html'
})
export class SearchComponent {
public sub: any; piwiksub: any;
diff --git a/portal-2/src/app/searchPages/searchUtils/advancedSearchForm.component.html b/portal-2/src/app/searchPages/searchUtils/advancedSearchForm.component.html
new file mode 100644
index 00000000..938ca3cd
--- /dev/null
+++ b/portal-2/src/app/searchPages/searchUtils/advancedSearchForm.component.html
@@ -0,0 +1,56 @@
+
+
diff --git a/portal-2/src/app/searchPages/searchUtils/advancedSearchForm.component.ts b/portal-2/src/app/searchPages/searchUtils/advancedSearchForm.component.ts
index 9d3d4420..1e7ef861 100644
--- a/portal-2/src/app/searchPages/searchUtils/advancedSearchForm.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/advancedSearchForm.component.ts
@@ -8,64 +8,7 @@ import {Dates} from '../../utils/string-utils.class';
@Component({
selector: 'advanced-search-form',
- template: `
-
-
- `
+ templateUrl: 'advancedSearchForm.component.html'
})
export class AdvancedSearchFormComponent {
@Input() entityType;
diff --git a/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.html b/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.html
new file mode 100644
index 00000000..ef3cddc7
--- /dev/null
+++ b/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.html
@@ -0,0 +1,49 @@
+
+
diff --git a/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.ts b/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.ts
index 6cc08ebc..e4ebe4de 100644
--- a/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/advancedSearchPage.component.ts
@@ -14,57 +14,7 @@ import {PiwikService} from '../../utils/piwik/piwik.service';
@Component({
selector: 'advanced-search-page',
- template: `
-
-
- `
+ templateUrl: 'advancedSearchPage.component.html'
})
export class AdvancedSearchPageComponent {
@Input() pageTitle = "";
diff --git a/portal-2/src/app/searchPages/searchUtils/browseStatistic.component.html b/portal-2/src/app/searchPages/searchUtils/browseStatistic.component.html
new file mode 100644
index 00000000..3eb79bc6
--- /dev/null
+++ b/portal-2/src/app/searchPages/searchUtils/browseStatistic.component.html
@@ -0,0 +1,50 @@
+
+
{{filter.title}}
+
No {{filter.title}} statistics found
+
+
+
+
+
+
+
+
+
+
{{filter.title}}
+
+
+
diff --git a/portal-2/src/app/searchPages/searchUtils/browseStatistic.component.ts b/portal-2/src/app/searchPages/searchUtils/browseStatistic.component.ts
index 931f0ad4..485e6d97 100644
--- a/portal-2/src/app/searchPages/searchUtils/browseStatistic.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/browseStatistic.component.ts
@@ -12,61 +12,7 @@ import {SearchUtilsClass} from '../searchUtils/searchUtils.class';
import {RouterHelper} from '../../utils/routerHelper.class';
@Component({
selector: 'browse-statistic',
- template: `
-
-
-
{{filter.title}}
-
No {{filter.title}} statistics found
-
-
-
-
-
-
-
-
-
-
{{filter.title}}
-
-
-
-
-
- `
+ templateUrl: 'browseStatistic.component.html'
})
export class BrowseStatisticComponent {
diff --git a/portal-2/src/app/searchPages/searchUtils/searchFilter.component.html b/portal-2/src/app/searchPages/searchUtils/searchFilter.component.html
new file mode 100644
index 00000000..fdf83db7
--- /dev/null
+++ b/portal-2/src/app/searchPages/searchUtils/searchFilter.component.html
@@ -0,0 +1,67 @@
+
+
0" class="uk-list">
+
+ {{_formatTitle(filter.title,filter.values.length)}}
+
+
+
+
+
+
+
+ {{_formatName(value)}}
+
({{value.number}})
+
+
+
0 && getNotSelectedValues(filter).length > 0" class="uk-grid-divider uk-margin-remove">
+
+
+
+ {{_formatName(value)}}
+
({{value.number}})
+
+
+
+
+
+
+
5" (click)="open()" [class]="(isDisabled)?'uk-disabled uk-link-muted':''">View more
+
+
+
+
+
+
+
+
+
+ {{filter.title}}
+
+
= 99" class="uk-article-meta uk-text-center">Showing top {{filter.values.length}} values.
+
+
+
+
+ {{_formatName(value)}}
+
({{value.number}})
+
+
0 && getNotSelectedValues(filter).length > 0" class="uk-grid-divider uk-margin-remove">
+
+
+ {{_formatName(value)}}
+
({{value.number}})
+
+
+
+
+
+
+
+
+
+
+
diff --git a/portal-2/src/app/searchPages/searchUtils/searchFilter.component.ts b/portal-2/src/app/searchPages/searchUtils/searchFilter.component.ts
index 5e3d4ad6..a120673c 100644
--- a/portal-2/src/app/searchPages/searchUtils/searchFilter.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/searchFilter.component.ts
@@ -6,75 +6,7 @@ import {Open} from '../../utils/modal/open.component';
@Component({
selector: 'search-filter',
- template: `
-
0" class="uk-list">
-
- {{_formatTitle(filter.title,filter.values.length)}}
-
-
-
-
-
-
-
- {{_formatName(value)}}
-
({{value.number}})
-
-
-
0 && getNotSelectedValues(filter).length > 0" class="uk-grid-divider uk-margin-remove">
-
-
-
- {{_formatName(value)}}
-
({{value.number}})
-
-
-
-
-
-
-
5" (click)="open()" [class]="(isDisabled)?'uk-disabled uk-link-muted':''">View more
-
-
-
-
-
-
-
-
-
- {{filter.title}}
-
-
= 99" class="uk-article-meta uk-text-center">Showing top {{filter.values.length}} values.
-
-
-
-
- {{_formatName(value)}}
-
({{value.number}})
-
-
0 && getNotSelectedValues(filter).length > 0" class="uk-grid-divider uk-margin-remove">
-
-
- {{_formatName(value)}}
-
({{value.number}})
-
-
-
-
-
-
-
-
-
-
-
-
- `
+ templateUrl: 'searchFilter.component.html'
})
export class SearchFilterComponent {
diff --git a/portal-2/src/app/searchPages/searchUtils/searchForm.component.ts b/portal-2/src/app/searchPages/searchUtils/searchForm.component.ts
index e292dfd4..0a6ba9a8 100644
--- a/portal-2/src/app/searchPages/searchUtils/searchForm.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/searchForm.component.ts
@@ -1,6 +1,7 @@
import {Component, Input, Output, EventEmitter} from '@angular/core';
import {Observable} from 'rxjs/Observable';
import {RouterHelper} from '../../utils/routerHelper.class';
+import {Router} from '@angular/router';
@Component({
selector: 'search-form',
@@ -13,16 +14,12 @@ import {RouterHelper} from '../../utils/routerHelper.class';
Search
-
+
Search
-
-
-
+
-
-
`
})
@@ -36,7 +33,7 @@ export class SearchFormComponent {
@Output() keywordChange = new EventEmitter();
- constructor () {
+ constructor (private _router:Router) {
}
ngOnInit() {
@@ -49,4 +46,7 @@ export class SearchFormComponent {
value: this.keyword
});
}
+ goTo() {
+ this._router.navigate(['/search/find'], { queryParams: this.routerHelper.createQueryParam('keyword',this.keyword) });
+ }
}
diff --git a/portal-2/src/app/searchPages/searchUtils/searchPage.component.html b/portal-2/src/app/searchPages/searchUtils/searchPage.component.html
new file mode 100644
index 00000000..a992d6bf
--- /dev/null
+++ b/portal-2/src/app/searchPages/searchUtils/searchPage.component.html
@@ -0,0 +1,107 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/portal-2/src/app/searchPages/searchUtils/searchPage.component.ts b/portal-2/src/app/searchPages/searchUtils/searchPage.component.ts
index 7b09f7e8..f87025f2 100644
--- a/portal-2/src/app/searchPages/searchUtils/searchPage.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/searchPage.component.ts
@@ -19,118 +19,8 @@ import {PiwikService} from '../../utils/piwik/piwik.service';
@Component({
selector: 'search-page',
- template: `
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- `
+ templateUrl: 'searchPage.component.html'
+
})
export class SearchPageComponent {
@Input() pageTitle = "";
diff --git a/portal-2/src/app/searchPages/searchUtils/searchPageTableView.component.html b/portal-2/src/app/searchPages/searchUtils/searchPageTableView.component.html
new file mode 100644
index 00000000..e97596f2
--- /dev/null
+++ b/portal-2/src/app/searchPages/searchUtils/searchPageTableView.component.html
@@ -0,0 +1,168 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
0">Keywords: {{searchUtils.keyword}}
+
+
+
+
+ 0"> {{filter.title}}:
+ {{value.name}}
+
+
+ ,
+
+
+
+
+
+ Clear All
+
+
+
+
+
+
+
No Results found
+
An Error Occured
+
Service not available
+
+
+
+
+
+
+
0" class="uk-offcanvas-content uk-hidden@m">
+
+
+
+
+
+
+
0" class=" search-filters uk-width-1-4@l uk-width-1-4@m uk-width-1-1@s uk-margin-large-top uk-visible@m">
+
+
+
+
+
+
+
+
+ 0">
+
+
+ {{searchUtils.totalResults}} content providers, page {{searchUtils.page}} of {{(totalPages())}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Name
+
+
+
+
+
+ Type
+
+
+
+
+
+ Country
+
+
+
+
+
+ Institution
+
+
+
+
+
+ Compatibility
+
+
+
+
+
+
+
+
+ 0">
+
+
+
+
+
+
+ [no title available]
+
+
+
+
+ {{dataprovider.type}}
+ -
+
+
+ {{country}}{{(i < ( dataprovider['countries'].slice(0,5).length-1))?", ":""}}{{(i == dataprovider['countries'].slice(0,5).length-1 && dataprovider['countries'].length > 5)?"...":""}}
+ -
+
+
+
+ {{org.name}} {{org.name}} {{(i < ( dataprovider['organizations'].slice(0,5).length-1))?", ":""}}{{(i == dataprovider['organizations'].slice(0,5).length-1 && dataprovider['organizations'].length > 5)?"...":""}}
+
+ -
+
+
+ {{dataprovider.compatibility}}
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/portal-2/src/app/searchPages/searchUtils/searchPageTableView.component.ts b/portal-2/src/app/searchPages/searchUtils/searchPageTableView.component.ts
index 10969242..2de14356 100644
--- a/portal-2/src/app/searchPages/searchUtils/searchPageTableView.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/searchPageTableView.component.ts
@@ -17,176 +17,8 @@ import {PiwikService} from '../../utils/piwik/piwik.service';
@Component({
selector: 'search-page-table',
- template: `
-
-
-
-
-
-
-
-
-
-
-
-
0">Keywords: {{searchUtils.keyword}}
-
-
-
-
- 0"> {{filter.title}}:
- {{value.name}}
-
-
- ,
-
-
-
-
-
- Clear All
-
-
-
-
-
-
-
No Results found
-
An Error Occured
-
Service not available
-
-
-
-
-
-
-
0" class="uk-offcanvas-content uk-hidden@m">
-
-
-
-
-
-
-
0" class=" search-filters uk-width-1-4@l uk-width-1-4@m uk-width-1-1@s uk-margin-large-top uk-visible@m">
-
-
-
-
-
-
-
-
- 0">
-
-
- {{searchUtils.totalResults}} content providers, page {{searchUtils.page}} of {{(totalPages())}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Name
-
-
-
-
-
- Type
-
-
-
-
-
- Country
-
-
-
-
-
- Institution
-
-
-
-
-
- Compatibility
-
-
-
-
-
-
-
-
- 0">
-
-
-
-
-
-
- [no title available]
-
-
-
-
- {{dataprovider.type}}
- -
-
-
- {{country}}{{(i < ( dataprovider['countries'].slice(0,5).length-1))?", ":""}}{{(i == dataprovider['countries'].slice(0,5).length-1 && dataprovider['countries'].length > 5)?"...":""}}
- -
-
-
-
- {{org.name}} {{org.name}} {{(i < ( dataprovider['organizations'].slice(0,5).length-1))?", ":""}}{{(i == dataprovider['organizations'].slice(0,5).length-1 && dataprovider['organizations'].length > 5)?"...":""}}
-
- -
-
-
- {{dataprovider.compatibility}}
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- `
-})
+ templateUrl:'searchPageTableView.component.html'
+ })
export class SearchPageTableViewComponent {
@Input() pageTitle = "";
@Input() results;
diff --git a/portal-2/src/app/searchPages/searchUtils/searchResult.component.html b/portal-2/src/app/searchPages/searchUtils/searchResult.component.html
new file mode 100644
index 00000000..8a0ebbf8
--- /dev/null
+++ b/portal-2/src/app/searchPages/searchUtils/searchResult.component.html
@@ -0,0 +1,123 @@
+
+
+ No Results found
+ An Error Occured
+ Requested page out of bounds
+ Service not available
+
+
+
+
+
+
+
+ Publisher: {{result.publisher}}
+
+ Country: {{result.country}}
+
+
+
+
+
+ {{result.description}}
+
+
+
+ Embargo End Date: {{result.embargoEndDate}}
+
+
+
+ Funder:
+
+
+
+ {{funder.funderShortname}} ,
+
+ (start {{result.startYear}} - end {{result.endYear}})
+
+
+
+ Type: {{result['type']}}
+ 0">
+ Country: {{country}}{{(i < ( result['countries'].slice(0,10).length-1))?", ":""}}{{(i == result['countries'].slice(0,10).length-1 && result['countries'].length > 10)?"...":""}}
+
+
+
+
+
+ Compatibility: {{result.compatibility}}
+
+
+ 0">
+ Subject: {{subject}}{{(i < ( result['subjects'].slice(0,10).length-1))?", ":""}}{{(i == result['subjects'].slice(0,10).length-1 && result['subjects'].length > 10)?"...":""}}
+
+
+
+
+
diff --git a/portal-2/src/app/searchPages/searchUtils/searchResult.component.ts b/portal-2/src/app/searchPages/searchUtils/searchResult.component.ts
index 19107234..ac9e968a 100644
--- a/portal-2/src/app/searchPages/searchUtils/searchResult.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/searchResult.component.ts
@@ -5,130 +5,7 @@ import {RouterHelper} from '../../utils/routerHelper.class';
@Component({
selector: 'search-result',
- template: `
-
- No Results found
- An Error Occured
- Requested page out of bounds
- Service not available
-
-
-
-
-
-
-
- Publisher: {{result.publisher}}
-
- Country: {{result.country}}
-
-
-
-
-
- {{result.description}}
-
-
-
- Embargo End Date: {{result.embargoEndDate}}
-
-
-
- Funder:
-
-
-
- {{funder.funderShortname}} ,
-
- (start {{result.startYear}} - end {{result.endYear}})
-
-
-
- Type: {{result['type']}}
- 0">
- Country: {{country}}{{(i < ( result['countries'].slice(0,10).length-1))?", ":""}}{{(i == result['countries'].slice(0,10).length-1 && result['countries'].length > 10)?"...":""}}
-
-
-
-
-
- Compatibility: {{result.compatibility}}
-
-
- 0">
- Subject: {{subject}}{{(i < ( result['subjects'].slice(0,10).length-1))?", ":""}}{{(i == result['subjects'].slice(0,10).length-1 && result['subjects'].length > 10)?"...":""}}
-
-
-
-
-
- `
+ templateUrl:'searchResult.component.html'
})
export class SearchResultComponent {
diff --git a/portal-2/src/app/searchPages/searchUtils/tabResult.component.html b/portal-2/src/app/searchPages/searchUtils/tabResult.component.html
new file mode 100644
index 00000000..c9f7fbc2
--- /dev/null
+++ b/portal-2/src/app/searchPages/searchUtils/tabResult.component.html
@@ -0,0 +1,121 @@
+
+
+
+
+
+
+
+
+ Publisher: {{result.publisher}}
+
+ Country: {{result.country}}
+
+
+
+
+
+ Embargo End Date: {{result.embargoEndDate}}
+
+
+
+
+
+
+
+ {{funder.funderShortname}} ,
+ (start {{result.startYear}} - end {{result.endYear}})
+
+
+
+
+ Type: {{result['type']}}
+ 0">
+ Country: {{result.countries}}
+
+
+
+
+
+ Compatibility: {{result.compatibility}}
+
+
+
+
diff --git a/portal-2/src/app/searchPages/searchUtils/tabResult.component.ts b/portal-2/src/app/searchPages/searchUtils/tabResult.component.ts
index bcdd45b8..39576e56 100644
--- a/portal-2/src/app/searchPages/searchUtils/tabResult.component.ts
+++ b/portal-2/src/app/searchPages/searchUtils/tabResult.component.ts
@@ -5,130 +5,8 @@ import {RouterHelper} from '../../utils/routerHelper.class';
@Component({
selector: 'tab-result',
- template: `
-
-
-
-
-
-
-
-
- Publisher: {{result.publisher}}
-
- Country: {{result.country}}
-
-
-
-
-
- Embargo End Date: {{result.embargoEndDate}}
-
-
-
-
-
-
-
- {{funder.funderShortname}} ,
- (start {{result.startYear}} - end {{result.endYear}})
-
-
-
-
- Type: {{result['type']}}
- 0">
- Country: {{result.countries}}
-
-
-
-
-
- Compatibility: {{result.compatibility}}
-
-
-
-
- `
-})
+ templateUrl: 'tabResult.component.html'
+ })
export class TabResultComponent {
@Input() results: SearchResult[];
diff --git a/portal-2/src/app/sharedComponents/bottom.component.html b/portal-2/src/app/sharedComponents/bottom.component.html
new file mode 100644
index 00000000..8f1e61c3
--- /dev/null
+++ b/portal-2/src/app/sharedComponents/bottom.component.html
@@ -0,0 +1,79 @@
+
+
+
diff --git a/portal-2/src/app/sharedComponents/bottom.component.ts b/portal-2/src/app/sharedComponents/bottom.component.ts
index 72eec52b..3ae13c03 100644
--- a/portal-2/src/app/sharedComponents/bottom.component.ts
+++ b/portal-2/src/app/sharedComponents/bottom.component.ts
@@ -3,89 +3,7 @@ import 'rxjs/Rx';
@Component({
selector: 'bottom',
- template: `
-
-
-
-
-
-`
+ templateUrl: 'bottom.component.html'
})
export class BottomComponent {
diff --git a/portal-2/src/app/sharedComponents/navigationBar.component.html b/portal-2/src/app/sharedComponents/navigationBar.component.html
new file mode 100644
index 00000000..9732aa0e
--- /dev/null
+++ b/portal-2/src/app/sharedComponents/navigationBar.component.html
@@ -0,0 +1,194 @@
+
+
+
+
diff --git a/portal-2/src/app/sharedComponents/navigationBar.component.ts b/portal-2/src/app/sharedComponents/navigationBar.component.ts
index 5c9fa208..d6633963 100644
--- a/portal-2/src/app/sharedComponents/navigationBar.component.ts
+++ b/portal-2/src/app/sharedComponents/navigationBar.component.ts
@@ -6,213 +6,7 @@ import {Session} from '../login/utils/helper.class';
@Component({
selector: 'navbar',
- template: `
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-`
+ templateUrl: 'navigationBar.component.html'
})
export class NavigationBarComponent {
public isAuthorized: boolean = false;
diff --git a/portal-2/src/app/utils/helper/helper.component.ts b/portal-2/src/app/utils/helper/helper.component.ts
index d2dee100..66c3c70c 100644
--- a/portal-2/src/app/utils/helper/helper.component.ts
+++ b/portal-2/src/app/utils/helper/helper.component.ts
@@ -6,13 +6,10 @@ import {OpenaireProperties} from '../properties/openaireProperties';
@Component({
selector: 'helper',
template: `
-
-
-
`
})
export class HelperComponent {