Revision 57496
Added by Konstantinos Triantafyllou over 4 years ago
app-routing.module.ts | ||
---|---|---|
1 | 1 |
import {NgModule} from '@angular/core'; |
2 |
import {RouterModule, Routes} from '@angular/router'; |
|
2 |
import {PreloadAllModules, RouterModule, Routes} from '@angular/router';
|
|
3 | 3 |
|
4 | 4 |
import {EnvironmentSpecificResolver} from './openaireLibrary/utils/properties/environmentSpecificResolver'; |
5 | 5 |
import {EnvironmentSpecificService} from './openaireLibrary/utils/properties/environment-specific.service'; |
... | ... | |
8 | 8 |
|
9 | 9 |
const routes: Routes = [ |
10 | 10 |
{ |
11 |
path: '', |
|
11 |
path: ':stakeholder', |
|
12 |
loadChildren: './home/home.module#HomeModule', |
|
13 |
resolve: {envSpecific: EnvironmentSpecificResolver} |
|
14 |
}, |
|
15 |
{ |
|
16 |
path: 'monitor', |
|
12 | 17 |
loadChildren: './monitor/monitor.module#MonitorModule', |
13 | 18 |
resolve: {envSpecific: EnvironmentSpecificResolver} |
14 | 19 |
}, |
... | ... | |
32 | 37 |
]; |
33 | 38 |
|
34 | 39 |
@NgModule({ |
35 |
imports: [RouterModule.forRoot(routes)], |
|
40 |
imports: [RouterModule.forRoot(routes, { |
|
41 |
preloadingStrategy: PreloadAllModules, |
|
42 |
scrollPositionRestoration: "top" |
|
43 |
})], |
|
36 | 44 |
exports: [RouterModule], |
37 | 45 |
providers: [EnvironmentSpecificResolver, EnvironmentSpecificService] |
38 | 46 |
}) |
Also available in: Unified diff
[Monitor_dashboard]:Initialize monitor admin. Home page has been created.