| .. | .. |
|---|
| 1 | | -import { NgModule } from '@angular/core'; |
|---|
| 2 | | -import { BrowserModule } from '@angular/platform-browser'; |
|---|
| 3 | | -import {BrowserAnimationsModule} from '@angular/platform-browser/animations'; |
|---|
| 4 | 1 | import { CommonModule } from '@angular/common'; |
|---|
| 2 | +import { NgModule, TypeProvider } from '@angular/core'; |
|---|
| 3 | +import { HttpModule } from '@angular/http'; |
|---|
| 4 | +import { BrowserModule } from '@angular/platform-browser'; |
|---|
| 5 | +import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; |
|---|
| 5 | 6 | import { FormsModule } from '@angular/forms'; |
|---|
| 6 | | -import {MaterialModule} from '@angular/material'; |
|---|
| 7 | | -import {CovalentCoreModule} from '@covalent/core'; |
|---|
| 8 | | -import {CovalentHttpModule} from '@covalent/http'; |
|---|
| 9 | | -import {CovalentDynamicFormsModule} from '@covalent/dynamic-forms'; |
|---|
| 7 | +import { MaterialModule } from '@angular/material'; |
|---|
| 8 | +import { CovalentCoreModule } from '@covalent/core'; |
|---|
| 9 | +import { CovalentHttpModule } from '@covalent/http'; |
|---|
| 10 | +import { CovalentDynamicFormsModule } from '@covalent/dynamic-forms'; |
|---|
| 10 | 11 | |
|---|
| 11 | | -import { LocalStorageModule } from 'angular-2-local-storage'; |
|---|
| 12 | +import { LockerModule, DRIVERS } from 'angular-safeguard'; |
|---|
| 13 | + |
|---|
| 12 | 14 | import { ToastModule } from 'ng2-toastr/ng2-toastr'; |
|---|
| 13 | 15 | |
|---|
| 14 | 16 | import { HomeComponent } from './home.component'; |
|---|
| 15 | | -import { I18nDirective } from './common/i18n'; |
|---|
| 16 | 17 | import { MetadataManagerComponent } from './forms/base'; |
|---|
| 17 | 18 | import { FieldReadonlyComponent } from './forms/base'; |
|---|
| 18 | 19 | import { ErrorCheckerComponent } from './forms/base'; |
|---|
| 20 | + |
|---|
| 21 | +import { LocaleServiceModule, I18nDirective, LocaleService } from './common/i18n'; |
|---|
| 19 | 22 | |
|---|
| 20 | 23 | import { UserService } from './user.service'; |
|---|
| 21 | 24 | import { PacksService } from './resources/packs'; |
|---|
| .. | .. |
|---|
| 42 | 45 | import { OrganizationFormComponent } from './forms/organization.form.component'; |
|---|
| 43 | 46 | import { UserFormComponent } from './forms/user.form.component'; |
|---|
| 44 | 47 | |
|---|
| 45 | | - |
|---|
| 46 | 48 | import { appRoutes, appRoutingProviders } from './app.routes'; |
|---|
| 47 | 49 | import { requestOptionsProvider, requestBackendProvider } from './common/default.requests.options'; |
|---|
| 48 | | -import { LocaleServiceModule } from './common/i18n'; |
|---|
| 49 | 50 | import { SeCurisSession } from './common/session'; |
|---|
| 51 | + |
|---|
| 52 | + |
|---|
| 50 | 53 | |
|---|
| 51 | 54 | @NgModule({ |
|---|
| 52 | 55 | imports: [ |
|---|
| 53 | | - LocalStorageModule.withConfig({ |
|---|
| 54 | | - prefix: 'securis', |
|---|
| 55 | | - storageType: 'localStorage' |
|---|
| 56 | + LocaleServiceModule.withConfig('en'), |
|---|
| 57 | + LockerModule.withConfig({ |
|---|
| 58 | + driverNamespace: 'securis', |
|---|
| 59 | + defaultDriverType: DRIVERS.LOCAL, |
|---|
| 60 | + namespaceSeparator: '-' |
|---|
| 56 | 61 | }), |
|---|
| 57 | 62 | BrowserModule, |
|---|
| 58 | 63 | BrowserAnimationsModule, |
|---|
| 64 | + HttpModule, |
|---|
| 59 | 65 | FormsModule, |
|---|
| 60 | 66 | MaterialModule, |
|---|
| 61 | 67 | CovalentCoreModule.forRoot(), |
|---|
| 62 | 68 | CovalentHttpModule.forRoot(), |
|---|
| 63 | 69 | CovalentDynamicFormsModule.forRoot(), |
|---|
| 64 | 70 | ToastModule.forRoot(), |
|---|
| 65 | | - LocaleServiceModule.withConfig('en'), |
|---|
| 66 | 71 | appRoutes, |
|---|
| 67 | 72 | ], |
|---|
| 68 | 73 | declarations: [ |
|---|
| 74 | + HomeComponent, |
|---|
| 69 | 75 | ApplicationListComponent, |
|---|
| 70 | 76 | ApplicationFormComponent, |
|---|
| 71 | 77 | PackListComponent, |
|---|
| .. | .. |
|---|
| 81 | 87 | OrganizationFormComponent, |
|---|
| 82 | 88 | UserFormComponent, |
|---|
| 83 | 89 | I18nDirective, |
|---|
| 84 | | - HomeComponent, |
|---|
| 85 | 90 | MenuComponent, |
|---|
| 86 | 91 | NoMenuComponent, |
|---|
| 87 | 92 | FieldReadonlyComponent, |
|---|
| .. | .. |
|---|
| 91 | 96 | bootstrap: [ HomeComponent ], |
|---|
| 92 | 97 | entryComponents: [ ], |
|---|
| 93 | 98 | providers: [ |
|---|
| 94 | | - SeCurisSession, |
|---|
| 99 | + SeCurisSession, |
|---|
| 95 | 100 | UserService, |
|---|
| 96 | 101 | PacksService, |
|---|
| 97 | 102 | LicensesService, |
|---|