diff --git a/portal-4cli-lib/src/app/app-routing.module.ts b/portal-4cli-lib/src/app/app-routing.module.ts index 66287bec..5f849711 100644 --- a/portal-4cli-lib/src/app/app-routing.module.ts +++ b/portal-4cli-lib/src/app/app-routing.module.ts @@ -44,6 +44,7 @@ const routes: Routes = [ { path: 'search/advanced/dataproviders', loadChildren: './searchPages/advanced/advancedSearchDataProviders.module#LibAdvancedSearchDataProvidersModule', resolve: { envSpecific: EnvironmentSpecificResolver }}, { path: 'search/advanced/projects', loadChildren: './searchPages/advanced/advancedSearchProjects.module#LibAdvancedSearchProjectsModule', resolve: { envSpecific: EnvironmentSpecificResolver }}, { path: 'project-report', loadChildren: './landingPages/htmlProjectReport/libHtmlProjectReport.module#LibHtmlProjectReportModule', resolve: { envSpecific: EnvironmentSpecificResolver }}, + { path: 'mail-preferences', loadChildren: './userEmailPreferences/mailPrefs.module#LibMailPrefsModule', resolve: { envSpecific: EnvironmentSpecificResolver }}, { path: 'myclaims', loadChildren: './claims/myClaims/myClaims.module#LibMyClaimsModule', resolve: { envSpecific: EnvironmentSpecificResolver }}, { path: 'claims', loadChildren: './claims/claimsAdmin/claimsAdmin.module#LibClaimsAdminModule', resolve: { envSpecific: EnvironmentSpecificResolver }}, { path: 'participate/claim', loadChildren: './claims/linking/linkingGeneric.module#LibLinkingGenericModule', resolve: { envSpecific: EnvironmentSpecificResolver }}, diff --git a/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs-routing.module.ts b/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs-routing.module.ts new file mode 100644 index 00000000..e3095e2b --- /dev/null +++ b/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs-routing.module.ts @@ -0,0 +1,17 @@ +import { NgModule } from '@angular/core'; +import { RouterModule } from '@angular/router'; + +import {OpenaireMailPrefsComponent } from './mailPrefs.component'; +import {LoginGuard} from '../openaireLibrary/login/loginGuard.guard'; +import {PreviousRouteRecorder} from '../openaireLibrary/utils/piwik/previousRouteRecorder.guard'; +import {IsRouteEnabled} from '../openaireLibrary/error/isRouteEnabled.guard'; + + +@NgModule({ + imports: [ + RouterModule.forChild([ + { path: '', component: OpenaireMailPrefsComponent, canActivate: [IsRouteEnabled, LoginGuard], + data: {redirect: '/error', community : 'openaire'}, canDeactivate: [PreviousRouteRecorder]}]) + ] +}) +export class MailPrefsRoutingModule { } diff --git a/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs.component.ts b/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs.component.ts new file mode 100644 index 00000000..dc8621fd --- /dev/null +++ b/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs.component.ts @@ -0,0 +1,20 @@ +import {Component, Input} from '@angular/core'; +import {Observable} from 'rxjs/Observable'; + + +@Component({ + selector: 'openaire-mailPrefs', + template: ` + +` + +}) + export class OpenaireMailPrefsComponent { + constructor () { + + } + ngOnInit() { + + } + +} diff --git a/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs.module.ts b/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs.module.ts new file mode 100644 index 00000000..db39296d --- /dev/null +++ b/portal-4cli-lib/src/app/userEmailPreferences/mailPrefs.module.ts @@ -0,0 +1,22 @@ +import { NgModule } from '@angular/core'; + +import { SharedModule } from '../shared/shared.module'; +import { OpenaireMailPrefsComponent } from './mailPrefs.component'; +import { MailPrefsRoutingModule } from './mailPrefs-routing.module'; +import { MailPrefsModule } from '../openaireLibrary/connect/userEmailPreferences/mailsPrefs.module'; +import { LoginGuard } from '../openaireLibrary/login/loginGuard.guard'; +import { PreviousRouteRecorder } from '../openaireLibrary/utils/piwik/previousRouteRecorder.guard'; +import { IsRouteEnabled } from '../openaireLibrary/error/isRouteEnabled.guard'; + +@NgModule({ + imports: [ + SharedModule, + MailPrefsRoutingModule, + MailPrefsModule + ], + providers:[LoginGuard, PreviousRouteRecorder, IsRouteEnabled], + declarations: [ + OpenaireMailPrefsComponent + ] +}) +export class LibMailPrefsModule { }