[Trunk|Library]: Use scroll function from 'HelperFunctions' class (utils folder).
git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-library/trunk/ng-openaire-library/src/app@55418 d315682c-612b-4755-9ff5-7f18f6832af3
This commit is contained in:
parent
6125f3553e
commit
c3ab3b18fa
|
@ -1,5 +1,5 @@
|
||||||
import {Component, ViewChild} from '@angular/core';
|
import {Component, ViewChild} from '@angular/core';
|
||||||
import {ElementRef, Input} from '@angular/core';
|
import {Input} from '@angular/core';
|
||||||
import {ActivatedRoute, Router} from '@angular/router';
|
import {ActivatedRoute, Router} from '@angular/router';
|
||||||
import {Title, Meta} from '@angular/platform-browser';
|
import {Title, Meta} from '@angular/platform-browser';
|
||||||
|
|
||||||
|
@ -29,6 +29,7 @@ import {ErrorCodes} from '../../utils/properties/errorCo
|
||||||
import {RouterHelper} from '../../utils/routerHelper.class';
|
import {RouterHelper} from '../../utils/routerHelper.class';
|
||||||
import {PiwikService} from '../../utils/piwik/piwik.service';
|
import {PiwikService} from '../../utils/piwik/piwik.service';
|
||||||
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
|
@ -95,16 +96,13 @@ export class DataProviderComponent {
|
||||||
private reloadDataproviders: boolean = true;
|
private reloadDataproviders: boolean = true;
|
||||||
private reloadRelatedDatasources: boolean = true;
|
private reloadRelatedDatasources: boolean = true;
|
||||||
|
|
||||||
private nativeElement : Node;
|
|
||||||
|
|
||||||
sub: any;
|
sub: any;
|
||||||
piwiksub: any;
|
piwiksub: any;
|
||||||
subInfo: any;
|
subInfo: any;
|
||||||
relatedDatasourcesSub: any;
|
relatedDatasourcesSub: any;
|
||||||
properties:EnvProperties;
|
properties:EnvProperties;
|
||||||
|
|
||||||
constructor (private element: ElementRef,
|
constructor (private _dataproviderService: DataProviderService,
|
||||||
private _dataproviderService: DataProviderService,
|
|
||||||
private _piwikService:PiwikService,
|
private _piwikService:PiwikService,
|
||||||
private route: ActivatedRoute,
|
private route: ActivatedRoute,
|
||||||
private _meta: Meta,
|
private _meta: Meta,
|
||||||
|
@ -142,9 +140,7 @@ export class DataProviderComponent {
|
||||||
this.getDataProviderInfo(this.datasourceId);
|
this.getDataProviderInfo(this.datasourceId);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import {Component, ViewChild} from '@angular/core';
|
import {Component, ViewChild} from '@angular/core';
|
||||||
import {ElementRef, Input} from '@angular/core';
|
import {Input} from '@angular/core';
|
||||||
import {ActivatedRoute, Router} from '@angular/router';
|
import {ActivatedRoute, Router} from '@angular/router';
|
||||||
import {Title, Meta} from '@angular/platform-browser';
|
import {Title, Meta} from '@angular/platform-browser';
|
||||||
|
|
||||||
|
@ -12,6 +12,7 @@ import {RouterHelper} from '../../utils/routerHelper.class';
|
||||||
import {DatasetService} from './dataset.service';
|
import {DatasetService} from './dataset.service';
|
||||||
import {PiwikService} from '../../utils/piwik/piwik.service';
|
import {PiwikService} from '../../utils/piwik/piwik.service';
|
||||||
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
|
@ -61,8 +62,7 @@ export class DatasetComponent {
|
||||||
sub: any; piwiksub: any; infoSub: any;
|
sub: any; piwiksub: any; infoSub: any;
|
||||||
properties:EnvProperties;
|
properties:EnvProperties;
|
||||||
|
|
||||||
constructor (private element: ElementRef,
|
constructor (private _datasetService: DatasetService,
|
||||||
private _datasetService: DatasetService,
|
|
||||||
private _piwikService:PiwikService,
|
private _piwikService:PiwikService,
|
||||||
private route: ActivatedRoute,
|
private route: ActivatedRoute,
|
||||||
private _meta: Meta,
|
private _meta: Meta,
|
||||||
|
@ -102,7 +102,7 @@ export class DatasetComponent {
|
||||||
this.downloadsFrameUrl = this.properties.framesAPIURL+'merge.php?com=query&data=[{"query":"resRepoDownloads", "resTitle":"'+this.datasetId+'", "table":"","fields":[{"fld":"sum","agg":"sum","type":"column","yaxis":1,"c":false}],"xaxis":{"name":"month","agg":"sum"},"group":" ","color":"","type":"chart","size":30,"sort":"xaxis","xStyle":{"r":-30,"s":"0","l":"-","ft":"-","wt":"-"},"title":"","subtitle":"","xaxistitle":"Repository","yaxisheaders":["Monthly downloads"],"generalxaxis":"","theme":0,"in":[],"filters":[{"name":"","values":[""],"to":"-1"}]}]&info_types=["column"]&stacking=normal&steps=false&fontFamily=Courier&spacing=[5,0,0,0]&style=[{"color":"rgba(0, 0, 0, 1)","size":"18"},{"color":"rgba(0, 0, 0, 1)","size":"18"},{"color":"000000","size":""},{"color":"000000","size":""}]&backgroundColor=rgba(255,255,255,1)&colors[]=rgba(67, 67, 72, 1)&colors[]=rgba(144, 237, 125, 1)&colors[]=rgba(247, 163, 92, 1)&colors[]=rgba(128, 133, 233, 1)&colors[]=rgba(241, 92, 128, 1)&colors[]=rgba(228, 211, 84, 1)&colors[]=rgba(43, 144, 143, 1)&colors[]=rgba(244, 91, 91, 1)&colors[]=rgba(145, 232, 225, 1)&xlinew=0&ylinew=1&legends=true&tooltips=true&persistent=false';
|
this.downloadsFrameUrl = this.properties.framesAPIURL+'merge.php?com=query&data=[{"query":"resRepoDownloads", "resTitle":"'+this.datasetId+'", "table":"","fields":[{"fld":"sum","agg":"sum","type":"column","yaxis":1,"c":false}],"xaxis":{"name":"month","agg":"sum"},"group":" ","color":"","type":"chart","size":30,"sort":"xaxis","xStyle":{"r":-30,"s":"0","l":"-","ft":"-","wt":"-"},"title":"","subtitle":"","xaxistitle":"Repository","yaxisheaders":["Monthly downloads"],"generalxaxis":"","theme":0,"in":[],"filters":[{"name":"","values":[""],"to":"-1"}]}]&info_types=["column"]&stacking=normal&steps=false&fontFamily=Courier&spacing=[5,0,0,0]&style=[{"color":"rgba(0, 0, 0, 1)","size":"18"},{"color":"rgba(0, 0, 0, 1)","size":"18"},{"color":"000000","size":""},{"color":"000000","size":""}]&backgroundColor=rgba(255,255,255,1)&colors[]=rgba(67, 67, 72, 1)&colors[]=rgba(144, 237, 125, 1)&colors[]=rgba(247, 163, 92, 1)&colors[]=rgba(128, 133, 233, 1)&colors[]=rgba(241, 92, 128, 1)&colors[]=rgba(228, 211, 84, 1)&colors[]=rgba(43, 144, 143, 1)&colors[]=rgba(244, 91, 91, 1)&colors[]=rgba(145, 232, 225, 1)&xlinew=0&ylinew=1&legends=true&tooltips=true&persistent=false';
|
||||||
/*this.downloadsFrameUrl = this.properties.framesAPIURL+'merge.php?com=query&data=[{"query":"resRepoDownloadTimeline", "resTitle":"'+this.datasetId+'", "table":"","fields":[{"fld":"sum","agg":"sum","type":"column","yaxis":1,"c":false}],"xaxis":{"name":"month","agg":"sum"},"group":" ","color":"","type":"chart","size":30,"sort":"xaxis","xStyle":{"r":-30,"s":"0","l":"-","ft":"-","wt":"-"},"title":"","subtitle":"","xaxistitle":"Repository","yaxisheaders":["Monthly downloads"],"generalxaxis":"","theme":0,"in":[],"filters":[{"name":"","values":[""],"to":"-1"}]}]&info_types=["column"]&stacking=normal&steps=false&fontFamily=Courier&spacing=[5,0,0,0]&style=[{"color":"rgba(0, 0, 0, 1)","size":"18"},{"color":"rgba(0, 0, 0, 1)","size":"18"},{"color":"000000","size":""},{"color":"000000","size":""}]&backgroundColor=rgba(255,255,255,1)&colors[]=rgba(67, 67, 72, 1)&colors[]=rgba(144, 237, 125, 1)&colors[]=rgba(247, 163, 92, 1)&colors[]=rgba(128, 133, 233, 1)&colors[]=rgba(241, 92, 128, 1)&colors[]=rgba(228, 211, 84, 1)&colors[]=rgba(43, 144, 143, 1)&colors[]=rgba(244, 91, 91, 1)&colors[]=rgba(145, 232, 225, 1)&xlinew=0&ylinew=1&legends=true&tooltips=true';
|
/*this.downloadsFrameUrl = this.properties.framesAPIURL+'merge.php?com=query&data=[{"query":"resRepoDownloadTimeline", "resTitle":"'+this.datasetId+'", "table":"","fields":[{"fld":"sum","agg":"sum","type":"column","yaxis":1,"c":false}],"xaxis":{"name":"month","agg":"sum"},"group":" ","color":"","type":"chart","size":30,"sort":"xaxis","xStyle":{"r":-30,"s":"0","l":"-","ft":"-","wt":"-"},"title":"","subtitle":"","xaxistitle":"Repository","yaxisheaders":["Monthly downloads"],"generalxaxis":"","theme":0,"in":[],"filters":[{"name":"","values":[""],"to":"-1"}]}]&info_types=["column"]&stacking=normal&steps=false&fontFamily=Courier&spacing=[5,0,0,0]&style=[{"color":"rgba(0, 0, 0, 1)","size":"18"},{"color":"rgba(0, 0, 0, 1)","size":"18"},{"color":"000000","size":""},{"color":"000000","size":""}]&backgroundColor=rgba(255,255,255,1)&colors[]=rgba(67, 67, 72, 1)&colors[]=rgba(144, 237, 125, 1)&colors[]=rgba(247, 163, 92, 1)&colors[]=rgba(128, 133, 233, 1)&colors[]=rgba(241, 92, 128, 1)&colors[]=rgba(228, 211, 84, 1)&colors[]=rgba(43, 144, 143, 1)&colors[]=rgba(244, 91, 91, 1)&colors[]=rgba(145, 232, 225, 1)&xlinew=0&ylinew=1&legends=true&tooltips=true';
|
||||||
*/
|
*/
|
||||||
this.scroll();
|
HelperFunctions.scroll();
|
||||||
});
|
});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -202,12 +202,6 @@ export class DatasetComponent {
|
||||||
return Array.from(map.keys());
|
return Array.from(map.keys());
|
||||||
}
|
}
|
||||||
|
|
||||||
public scroll() {
|
|
||||||
if (typeof document !== 'undefined') {
|
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private handleError(message: string, error) {
|
private handleError(message: string, error) {
|
||||||
console.error("Research Data Landing Page: "+message, error);
|
console.error("Research Data Landing Page: "+message, error);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import {Component, Input, ElementRef} from '@angular/core';
|
import {Component, Input} from '@angular/core';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'availableOn',
|
selector: 'availableOn',
|
||||||
|
@ -64,13 +65,11 @@ export class AvailableOnComponent {
|
||||||
public threshold: number = 5;
|
public threshold: number = 5;
|
||||||
public showNum: number = 5;
|
public showNum: number = 5;
|
||||||
|
|
||||||
constructor (private element: ElementRef) {}
|
constructor () {}
|
||||||
|
|
||||||
ngOnInit() {}
|
ngOnInit() {}
|
||||||
|
|
||||||
public scroll() {
|
public scroll() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import {Component, Input, ElementRef} from '@angular/core';
|
import {Component, Input} from '@angular/core';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'fundedBy',
|
selector: 'fundedBy',
|
||||||
|
@ -71,7 +72,7 @@ export class FundedByComponent {
|
||||||
public threshold: number = 5;
|
public threshold: number = 5;
|
||||||
public showNum: number = 5;
|
public showNum: number = 5;
|
||||||
|
|
||||||
constructor (private element: ElementRef) {}
|
constructor () {}
|
||||||
|
|
||||||
ngOnInit() {}
|
ngOnInit() {}
|
||||||
|
|
||||||
|
@ -124,8 +125,6 @@ export class FundedByComponent {
|
||||||
}
|
}
|
||||||
|
|
||||||
public scroll() {
|
public scroll() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import {Component, Input, ElementRef} from '@angular/core';
|
import {Component, Input} from '@angular/core';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'publishedIn',
|
selector: 'publishedIn',
|
||||||
|
@ -54,14 +55,12 @@ export class PublishedInComponent {
|
||||||
|
|
||||||
public showAll: boolean = false;
|
public showAll: boolean = false;
|
||||||
|
|
||||||
constructor (private element: ElementRef) {}
|
constructor () {}
|
||||||
|
|
||||||
ngOnInit() {}
|
ngOnInit() {}
|
||||||
|
|
||||||
public scroll() {
|
public scroll() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
public getKeys( map) {
|
public getKeys( map) {
|
||||||
return Array.from(map.keys());
|
return Array.from(map.keys());
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
import {Component, Input, ElementRef} from '@angular/core';
|
import {Component, Input} from '@angular/core';
|
||||||
import {RouterHelper} from '../../utils/routerHelper.class';
|
import {RouterHelper} from '../../utils/routerHelper.class';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'showAuthors',
|
selector: 'showAuthors',
|
||||||
|
@ -46,7 +47,7 @@ export class ShowAuthorsComponent {
|
||||||
public showAll: boolean = false;
|
public showAll: boolean = false;
|
||||||
public routerHelper:RouterHelper = new RouterHelper();
|
public routerHelper:RouterHelper = new RouterHelper();
|
||||||
|
|
||||||
constructor (private element: ElementRef) {
|
constructor () {
|
||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
|
@ -57,8 +58,6 @@ export class ShowAuthorsComponent {
|
||||||
}
|
}
|
||||||
|
|
||||||
public scroll() {
|
public scroll() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import {Component, Input, ElementRef} from '@angular/core';
|
import {Component, Input} from '@angular/core';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'showIdentifiers',
|
selector: 'showIdentifiers',
|
||||||
|
@ -47,7 +48,7 @@ export class ShowIdentifiersComponent {
|
||||||
public sizeOfPreviousIdentifiers: number = -1;
|
public sizeOfPreviousIdentifiers: number = -1;
|
||||||
public pageSize: number = 10;
|
public pageSize: number = 10;
|
||||||
|
|
||||||
constructor (private element: ElementRef) {
|
constructor () {
|
||||||
this.doiURL = "https://dx.doi.org/";
|
this.doiURL = "https://dx.doi.org/";
|
||||||
this.pmcURL = "http://europepmc.org/articles/";
|
this.pmcURL = "http://europepmc.org/articles/";
|
||||||
this.handleURL = "http://hdl.handle.net/";
|
this.handleURL = "http://hdl.handle.net/";
|
||||||
|
@ -84,9 +85,7 @@ export class ShowIdentifiersComponent {
|
||||||
}
|
}
|
||||||
|
|
||||||
public scroll() {
|
public scroll() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
public getKeys( map) {
|
public getKeys( map) {
|
||||||
return Array.from(map.keys());
|
return Array.from(map.keys());
|
||||||
|
|
|
@ -27,6 +27,7 @@ import {PiwikService} from '../../utils/piwik/piwik.service';
|
||||||
import {StringUtils} from '../../utils/string-utils.class';
|
import {StringUtils} from '../../utils/string-utils.class';
|
||||||
import {EnvProperties} from '../../utils/properties/env-properties';
|
import {EnvProperties} from '../../utils/properties/env-properties';
|
||||||
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'organization',
|
selector: 'organization',
|
||||||
|
@ -142,9 +143,7 @@ export class OrganizationComponent {
|
||||||
this.warningMessage="No valid organization id";
|
this.warningMessage="No valid organization id";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
|
|
||||||
this.csvParamsTail = '" and relorganizationid exact "'+this.organizationId+'" ))';
|
this.csvParamsTail = '" and relorganizationid exact "'+this.organizationId+'" ))';
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import {Component, ViewChild} from '@angular/core';
|
import {Component, ViewChild} from '@angular/core';
|
||||||
import {ElementRef, Input} from '@angular/core';
|
import {Input} from '@angular/core';
|
||||||
import {ActivatedRoute, Router} from '@angular/router';
|
import {ActivatedRoute, Router} from '@angular/router';
|
||||||
import {Title, Meta} from '@angular/platform-browser';
|
import {Title, Meta} from '@angular/platform-browser';
|
||||||
|
|
||||||
|
@ -12,6 +12,7 @@ import {RouterHelper} from '../../utils/routerHelper.class';
|
||||||
import {OrpService} from './orp.service';
|
import {OrpService} from './orp.service';
|
||||||
import {PiwikService} from '../../utils/piwik/piwik.service';
|
import {PiwikService} from '../../utils/piwik/piwik.service';
|
||||||
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
|
@ -61,8 +62,7 @@ export class OrpComponent {
|
||||||
sub: any; piwiksub: any; infoSub: any;
|
sub: any; piwiksub: any; infoSub: any;
|
||||||
properties:EnvProperties;
|
properties:EnvProperties;
|
||||||
|
|
||||||
constructor (private element: ElementRef,
|
constructor (private _orpService: OrpService,
|
||||||
private _orpService: OrpService,
|
|
||||||
private _piwikService:PiwikService,
|
private _piwikService:PiwikService,
|
||||||
private route: ActivatedRoute,
|
private route: ActivatedRoute,
|
||||||
private _meta: Meta,
|
private _meta: Meta,
|
||||||
|
@ -189,9 +189,7 @@ export class OrpComponent {
|
||||||
}
|
}
|
||||||
|
|
||||||
public scroll() {
|
public scroll() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private handleError(message: string, error) {
|
private handleError(message: string, error) {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import {Component, ViewChild} from '@angular/core';
|
import {Component, ViewChild} from '@angular/core';
|
||||||
import {ElementRef, Input} from '@angular/core';
|
import {Input} from '@angular/core';
|
||||||
import {ActivatedRoute, Router} from '@angular/router';
|
import {ActivatedRoute, Router} from '@angular/router';
|
||||||
import {Params} from '@angular/router';
|
import {Params} from '@angular/router';
|
||||||
import {Title, Meta} from '@angular/platform-browser';
|
import {Title, Meta} from '@angular/platform-browser';
|
||||||
|
@ -27,6 +27,7 @@ import {ErrorCodes} from '../../utils/properties/errorCodes'
|
||||||
import {PiwikService} from '../../utils/piwik/piwik.service';
|
import {PiwikService} from '../../utils/piwik/piwik.service';
|
||||||
import {EnvProperties} from '../../utils/properties/env-properties';
|
import {EnvProperties} from '../../utils/properties/env-properties';
|
||||||
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'project',
|
selector: 'project',
|
||||||
|
@ -101,8 +102,7 @@ export class ProjectComponent{
|
||||||
|
|
||||||
sub: any; piwiksub: any; infoSub: any; downloadFilePiwikSub: any;
|
sub: any; piwiksub: any; infoSub: any; downloadFilePiwikSub: any;
|
||||||
properties:EnvProperties;
|
properties:EnvProperties;
|
||||||
constructor ( private element: ElementRef,
|
constructor ( private _projectService: ProjectService,
|
||||||
private _projectService: ProjectService,
|
|
||||||
private _piwikService:PiwikService,
|
private _piwikService:PiwikService,
|
||||||
private route: ActivatedRoute,
|
private route: ActivatedRoute,
|
||||||
private _searchPublicationsService: SearchPublicationsService,
|
private _searchPublicationsService: SearchPublicationsService,
|
||||||
|
@ -161,9 +161,7 @@ properties:EnvProperties;
|
||||||
this.csvParamsSoftware = "?format=csv-special&type=software&fq=(((oaftype exact result) and (resulttypeid exact software)) and (relprojectid exact \""+this.projectId+"\"))";
|
this.csvParamsSoftware = "?format=csv-special&type=software&fq=(((oaftype exact result) and (resulttypeid exact software)) and (relprojectid exact \""+this.projectId+"\"))";
|
||||||
this.csvParamsOrps = "?format=csv-special&type=other&fq=(((oaftype exact result) and (resulttypeid exact other)) and (relprojectid exact \""+this.projectId+"\"))";
|
this.csvParamsOrps = "?format=csv-special&type=other&fq=(((oaftype exact result) and (resulttypeid exact other)) and (relprojectid exact \""+this.projectId+"\"))";
|
||||||
|
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import {Component, ViewChild} from '@angular/core';
|
import {Component, ViewChild} from '@angular/core';
|
||||||
import {ElementRef, Input} from '@angular/core';
|
import {Input} from '@angular/core';
|
||||||
import {ActivatedRoute, Router} from '@angular/router';
|
import {ActivatedRoute, Router} from '@angular/router';
|
||||||
import {Title, Meta} from '@angular/platform-browser';
|
import {Title, Meta} from '@angular/platform-browser';
|
||||||
|
|
||||||
|
@ -12,6 +12,7 @@ import {RouterHelper} from '../../utils/routerHelper.class';
|
||||||
import {PiwikService} from '../../utils/piwik/piwik.service';
|
import {PiwikService} from '../../utils/piwik/piwik.service';
|
||||||
import {PublicationService} from './publication.service';
|
import {PublicationService} from './publication.service';
|
||||||
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
|
@ -72,8 +73,7 @@ export class PublicationComponent {
|
||||||
sub: any; piwiksub: any; infoSub: any;
|
sub: any; piwiksub: any; infoSub: any;
|
||||||
properties:EnvProperties;
|
properties:EnvProperties;
|
||||||
|
|
||||||
constructor ( private element: ElementRef,
|
constructor ( private _publicationService: PublicationService,
|
||||||
private _publicationService: PublicationService,
|
|
||||||
private _piwikService:PiwikService,
|
private _piwikService:PiwikService,
|
||||||
private route: ActivatedRoute,
|
private route: ActivatedRoute,
|
||||||
private _meta: Meta,
|
private _meta: Meta,
|
||||||
|
@ -293,9 +293,7 @@ export class PublicationComponent {
|
||||||
}
|
}
|
||||||
|
|
||||||
public scroll() {
|
public scroll() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
start(i: number, bioentitiesPage: number) {
|
start(i: number, bioentitiesPage: number) {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import {Component, ViewChild} from '@angular/core';
|
import {Component, ViewChild} from '@angular/core';
|
||||||
import {ElementRef, Input} from '@angular/core';
|
import {Input} from '@angular/core';
|
||||||
import {ActivatedRoute, Router} from '@angular/router';
|
import {ActivatedRoute, Router} from '@angular/router';
|
||||||
import {Title, Meta} from '@angular/platform-browser';
|
import {Title, Meta} from '@angular/platform-browser';
|
||||||
|
|
||||||
|
@ -12,6 +12,7 @@ import {RouterHelper} from '../../utils/routerHelper.class';
|
||||||
import {PiwikService} from '../../utils/piwik/piwik.service';
|
import {PiwikService} from '../../utils/piwik/piwik.service';
|
||||||
import {EnvProperties} from '../../utils/properties/env-properties';
|
import {EnvProperties} from '../../utils/properties/env-properties';
|
||||||
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'software',
|
selector: 'software',
|
||||||
|
@ -56,8 +57,7 @@ export class SoftwareComponent {
|
||||||
sub: any; piwiksub: any; infoSub: any;
|
sub: any; piwiksub: any; infoSub: any;
|
||||||
properties:EnvProperties;
|
properties:EnvProperties;
|
||||||
|
|
||||||
constructor (private element: ElementRef,
|
constructor (private _softwareService: SoftwareService,
|
||||||
private _softwareService: SoftwareService,
|
|
||||||
private _piwikService:PiwikService,
|
private _piwikService:PiwikService,
|
||||||
private route: ActivatedRoute,
|
private route: ActivatedRoute,
|
||||||
private _meta: Meta,
|
private _meta: Meta,
|
||||||
|
@ -196,9 +196,7 @@ export class SoftwareComponent {
|
||||||
}
|
}
|
||||||
|
|
||||||
public scroll() {
|
public scroll() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private handleError(message: string, error) {
|
private handleError(message: string, error) {
|
||||||
|
|
|
@ -1,11 +1,7 @@
|
||||||
import {Component, Input, Output, EventEmitter, ViewChild, ElementRef} from '@angular/core';
|
import {Component} from '@angular/core';
|
||||||
import {Observable} from 'rxjs/Observable';
|
|
||||||
import {ActivatedRoute, Router} from '@angular/router';
|
import {ActivatedRoute, Router} from '@angular/router';
|
||||||
import {Location} from '@angular/common';
|
|
||||||
|
|
||||||
import {ErrorCodes} from '../utils/properties/errorCodes';
|
|
||||||
import {RouterHelper} from '../utils/routerHelper.class';
|
|
||||||
import {Session} from '../login/utils/helper.class';
|
import {Session} from '../login/utils/helper.class';
|
||||||
|
import {HelperFunctions} from "../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'reload',
|
selector: 'reload',
|
||||||
|
@ -23,18 +19,11 @@ import {Session} from '../login/utils/helper.class';
|
||||||
})
|
})
|
||||||
export class ReloadComponent {
|
export class ReloadComponent {
|
||||||
|
|
||||||
constructor (private element: ElementRef,
|
constructor (private route: ActivatedRoute, private _router: Router) {}
|
||||||
private route: ActivatedRoute,
|
|
||||||
private _router: Router,
|
|
||||||
private location: Location
|
|
||||||
) {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
public ngOnInit() {
|
public ngOnInit() {
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
var URL = Session.getReloadUrl();
|
var URL = Session.getReloadUrl();
|
||||||
|
|
||||||
if(URL && URL["path"] && URL["path"] != null && URL["path"] != ""){
|
if(URL && URL["path"] && URL["path"] != null && URL["path"] != ""){
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import {Component, Input} from '@angular/core';
|
import {Component, Input} from '@angular/core';
|
||||||
import {ViewChild, Output} from '@angular/core';
|
import {ViewChild, Output} from '@angular/core';
|
||||||
import {EventEmitter,ElementRef} from '@angular/core';
|
import {EventEmitter} from '@angular/core';
|
||||||
import {Location} from '@angular/common';
|
import {Location} from '@angular/common';
|
||||||
import {Router, ActivatedRoute} from '@angular/router';
|
import {Router, ActivatedRoute} from '@angular/router';
|
||||||
import {Title, Meta} from '@angular/platform-browser';
|
import {Title, Meta} from '@angular/platform-browser';
|
||||||
|
@ -15,6 +15,7 @@ import {ErrorCodes} from '../../utils/properties/errorCodes';
|
||||||
import {PiwikService} from '../../utils/piwik/piwik.service';
|
import {PiwikService} from '../../utils/piwik/piwik.service';
|
||||||
import {EnvProperties} from '../../utils/properties/env-properties';
|
import {EnvProperties} from '../../utils/properties/env-properties';
|
||||||
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
import { SEOService } from '../../sharedComponents/SEO/SEO.service';
|
||||||
|
import {HelperFunctions} from "../../utils/HelperFunctions.class";
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'search-page',
|
selector: 'search-page',
|
||||||
|
@ -78,7 +79,6 @@ export class SearchPageComponent {
|
||||||
private location: Location,
|
private location: Location,
|
||||||
private _meta: Meta,
|
private _meta: Meta,
|
||||||
private _title: Title,
|
private _title: Title,
|
||||||
private element: ElementRef,
|
|
||||||
private _piwikService:PiwikService,
|
private _piwikService:PiwikService,
|
||||||
private router: Router,
|
private router: Router,
|
||||||
private seoService: SEOService) {
|
private seoService: SEOService) {
|
||||||
|
@ -99,9 +99,8 @@ export class SearchPageComponent {
|
||||||
this.piwiksub = this._piwikService.trackView(this.properties, this.pageTitle, this.piwikSiteId).subscribe();
|
this.piwiksub = this._piwikService.trackView(this.properties, this.pageTitle, this.piwikSiteId).subscribe();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
// this.updateBaseUrlWithParameters(this.filters);
|
// this.updateBaseUrlWithParameters(this.filters);
|
||||||
this.updateTitle(this.pageTitle);
|
this.updateTitle(this.pageTitle);
|
||||||
var description = "Openaire, search, repositories, open access, type, content provider, funder, project, " + this.type + "," +this.pageTitle;
|
var description = "Openaire, search, repositories, open access, type, content provider, funder, project, " + this.type + "," +this.pageTitle;
|
||||||
|
@ -550,9 +549,7 @@ export class SearchPageComponent {
|
||||||
index:indexQuery,
|
index:indexQuery,
|
||||||
params: this.queryParameters
|
params: this.queryParameters
|
||||||
});
|
});
|
||||||
if (typeof document !== 'undefined') {
|
HelperFunctions.scroll();
|
||||||
this.element.nativeElement.scrollIntoView();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
filterChanged($event){
|
filterChanged($event){
|
||||||
this.goTo(1);
|
this.goTo(1);
|
||||||
|
|
Loading…
Reference in New Issue