[ACS-3551] feat: add context to outgoing requests for auth intgerceptors (#7913)

This commit is contained in:
Mikołaj Serwicki
2022-10-24 10:28:06 +02:00
committed by GitHub
parent 2d57ca31ca
commit 18a5197b5a
14 changed files with 246 additions and 23 deletions

View File

@@ -20,7 +20,7 @@ import { APP_INITIALIZER, NgModule } from '@angular/core';
import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { FlexLayoutModule } from '@angular/flex-layout';
import { ChartsModule } from 'ng2-charts';
import { HttpClientModule } from '@angular/common/http';
import { HttpClientModule, HTTP_INTERCEPTORS } from '@angular/common/http';
import { BrowserAnimationsModule, NoopAnimationsModule } from '@angular/platform-browser/animations';
import { TranslateModule } from '@ngx-translate/core';
import {
@@ -28,7 +28,8 @@ import {
TRANSLATION_PROVIDER,
DebugAppConfigService,
CoreModule,
CoreAutomationService
CoreAutomationService,
AuthBearerInterceptor
} from '@alfresco/adf-core';
import { ExtensionsModule } from '@alfresco/adf-extensions';
import { AppComponent } from './app.component';
@@ -208,6 +209,10 @@ registerLocaleData(localeSv);
SearchFilterChipsComponent
],
providers: [
{
provide: HTTP_INTERCEPTORS, useClass:
AuthBearerInterceptor, multi: true
},
{ provide: AppConfigService, useClass: DebugAppConfigService }, // not use this service in production
{
provide: TRANSLATION_PROVIDER,