forked from jebaGem/AngularRedux
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsearch-customer.module.ts
More file actions
50 lines (47 loc) · 1.8 KB
/
search-customer.module.ts
File metadata and controls
50 lines (47 loc) · 1.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { HttpClientModule, HttpClient } from '@angular/common/http';
import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
import { TranslateHttpLoader } from '@ngx-translate/http-loader';
import { EuppTranslateLoader } from '../shared/translation/eupp-translate-loader';
import {
EuppConfigureTranslateService
} from '../shared/translation/eupp-configure-translate.service';
import { TranslationKeys } from '../shared/translation/translation-keys';
import { SharedModule } from '../shared/shared.module';
import { ApiService } from '../core/account/api.service';
import { ReactiveFormsModule } from '@angular/forms';
import { SearchCustomerComponent } from './search-customer.component';
import { SearchCustomerActions } from './search-customer.actions';
import { SearchCustomerEpics } from './search-customer.epics';
// This Factory is default loader for the Translation
export function translateLoaderFactory(http: HttpClient, apiService: ApiService) {
return new EuppTranslateLoader(http, apiService);
}
@NgModule({
imports: [
CommonModule,
ReactiveFormsModule,
SharedModule,
TranslateModule.forRoot(
{
loader: {
provide: TranslateLoader,
useFactory: translateLoaderFactory,
deps: [HttpClient, ApiService]
}
}
)
],
declarations: [SearchCustomerComponent],
providers: [
{ provide: 'components', useValue: [SearchCustomerComponent], multi: true },
EuppConfigureTranslateService,
TranslationKeys,
SearchCustomerActions,
SearchCustomerEpics
],
exports: [SearchCustomerComponent],
entryComponents: [SearchCustomerComponent]
})
export class SearchCustomerModule { }