aboutsummaryrefslogtreecommitdiffstats
path: root/so-monitoring/so-monitoring-ui/src/main/frontend/src/app/app.module.ts
diff options
context:
space:
mode:
Diffstat (limited to 'so-monitoring/so-monitoring-ui/src/main/frontend/src/app/app.module.ts')
-rw-r--r--so-monitoring/so-monitoring-ui/src/main/frontend/src/app/app.module.ts18
1 files changed, 14 insertions, 4 deletions
diff --git a/so-monitoring/so-monitoring-ui/src/main/frontend/src/app/app.module.ts b/so-monitoring/so-monitoring-ui/src/main/frontend/src/app/app.module.ts
index 23308639b6..71294bfffe 100644
--- a/so-monitoring/so-monitoring-ui/src/main/frontend/src/app/app.module.ts
+++ b/so-monitoring/so-monitoring-ui/src/main/frontend/src/app/app.module.ts
@@ -2,6 +2,8 @@
============LICENSE_START=======================================================
Copyright (C) 2018 Ericsson. All rights reserved.
================================================================================
+ Modifications Copyright (c) 2019 Samsung
+================================================================================
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
@@ -28,7 +30,7 @@ import { AppComponent } from './app.component';
import { SidebarComponent } from './sidebar/sidebar.component';
import { TopbarComponent } from './topbar/topbar.component';
import { HomeComponent } from './home/home.component';
-import { HttpClientModule } from '@angular/common/http';
+import { HttpClientModule, HTTP_INTERCEPTORS } from '@angular/common/http';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { DetailsComponent } from './details/details.component';
import { ToastrNotificationService } from './toastr-notification-service.service';
@@ -37,6 +39,9 @@ import { MatFormFieldModule, MatInputModule, MatTableModule, MatTabsModule, MatS
import { NgxSpinnerModule } from 'ngx-spinner';
import { RouterModule, Routes } from '@angular/router';
import { APP_BASE_HREF } from '@angular/common';
+import { LoginComponent } from './login/login.component';
+import {BasicAuthInterceptor} from "./basic-auth.interceptor";
+import {ErrorInterceptor} from "./error.interceptor";
@NgModule({
declarations: [
@@ -44,7 +49,8 @@ import { APP_BASE_HREF } from '@angular/common';
SidebarComponent,
TopbarComponent,
HomeComponent,
- DetailsComponent
+ DetailsComponent,
+ LoginComponent
],
imports: [
BrowserModule,
@@ -64,12 +70,16 @@ import { APP_BASE_HREF } from '@angular/common';
RouterModule,
MatPaginatorModule,
MatSortModule,
- RouterModule.forRoot([])
+ RouterModule.forRoot([]),
+ ReactiveFormsModule
],
schemas: [
CUSTOM_ELEMENTS_SCHEMA
],
- providers: [ToastrNotificationService],
+ providers: [
+ { provide: HTTP_INTERCEPTORS, useClass: BasicAuthInterceptor, multi: true },
+ { provide: HTTP_INTERCEPTORS, useClass: ErrorInterceptor, multi: true },
+ ToastrNotificationService],
bootstrap: [AppComponent]
})
export class AppModule { }