]>
Commit | Line | Data |
---|---|---|
df98563e | 1 | import { CommonModule } from '@angular/common' |
78967fca | 2 | import { NgModule, Optional, SkipSelf } from '@angular/core' |
1f30a185 | 3 | import { FormsModule } from '@angular/forms' |
e7dbeae8 | 4 | import { BrowserAnimationsModule } from '@angular/platform-browser/animations' |
78967fca | 5 | import { RouterModule } from '@angular/router' |
68e24d72 C |
6 | import { LoadingBarModule } from '@ngx-loading-bar/core' |
7 | import { LoadingBarHttpClientModule } from '@ngx-loading-bar/http-client' | |
998acc22 | 8 | import { LoadingBarRouterModule } from '@ngx-loading-bar/router' |
693b1aba | 9 | |
df98563e C |
10 | import { SimpleNotificationsModule } from 'angular2-notifications' |
11 | import { ModalModule } from 'ngx-bootstrap/modal' | |
7ddd02c9 | 12 | |
954605a8 | 13 | import { AuthService } from './auth' |
df98563e | 14 | import { ConfirmComponent, ConfirmService } from './confirm' |
df98563e | 15 | import { throwIfAlreadyLoaded } from './module-import-guard' |
901637bb | 16 | import { LoginGuard, RedirectService, UserRightGuard } from './routing' |
78967fca | 17 | import { ServerService } from './server' |
693b1aba C |
18 | |
19 | @NgModule({ | |
20 | imports: [ | |
21 | CommonModule, | |
7ddd02c9 | 22 | RouterModule, |
1f30a185 | 23 | FormsModule, |
e7dbeae8 | 24 | BrowserAnimationsModule, |
7ddd02c9 | 25 | |
5769e1db | 26 | ModalModule, |
68e24d72 C |
27 | SimpleNotificationsModule.forRoot(), |
28 | ||
29 | LoadingBarHttpClientModule, | |
998acc22 | 30 | LoadingBarRouterModule, |
68e24d72 | 31 | LoadingBarModule.forRoot() |
693b1aba | 32 | ], |
5769e1db | 33 | |
b99290b1 | 34 | declarations: [ |
b33f657c | 35 | ConfirmComponent |
b99290b1 | 36 | ], |
5769e1db | 37 | |
b99290b1 | 38 | exports: [ |
7ddd02c9 | 39 | SimpleNotificationsModule, |
68e24d72 C |
40 | LoadingBarHttpClientModule, |
41 | LoadingBarModule, | |
7ddd02c9 | 42 | |
b33f657c | 43 | ConfirmComponent |
b99290b1 | 44 | ], |
5769e1db C |
45 | |
46 | providers: [ | |
47 | AuthService, | |
92fb909c | 48 | ConfirmService, |
f47bf2e1 | 49 | ServerService, |
954605a8 | 50 | LoginGuard, |
901637bb C |
51 | UserRightGuard, |
52 | RedirectService | |
5769e1db | 53 | ] |
693b1aba C |
54 | }) |
55 | export class CoreModule { | |
7a8032bb | 56 | constructor (@Optional() @SkipSelf() parentModule: CoreModule) { |
df98563e | 57 | throwIfAlreadyLoaded(parentModule, 'CoreModule') |
693b1aba C |
58 | } |
59 | } |