Issue fixing + deletion of profile & logo

This commit is contained in:
2024-05-17 14:50:50 -05:00
parent 0684b9534f
commit df4e2b00e2
23 changed files with 774 additions and 364 deletions

View File

@@ -1,20 +1,19 @@
import { APP_INITIALIZER, ApplicationConfig, LOCALE_ID, importProvidersFrom } from '@angular/core';
import { provideRouter } from '@angular/router';
import { APP_INITIALIZER, ApplicationConfig } from '@angular/core';
import { provideRouter, withEnabledBlockingInitialNavigation, withInMemoryScrolling } from '@angular/router';
import { routes } from './app.routes';
import { provideClientHydration } from '@angular/platform-browser';
import { HTTP_INTERCEPTORS, provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';
import { provideAnimations } from '@angular/platform-browser/animations';
import { HTTP_INTERCEPTORS, provideHttpClient, withFetch, withInterceptors, withInterceptorsFromDi } from '@angular/common/http';
import { environment } from '../environments/environment';
import { SelectOptionsService } from './services/select-options.service';
import { KeycloakService } from './services/keycloak.service';
import { UserService } from './services/user.service';
import { routes } from './app.routes';
import { LoadingInterceptor } from './interceptors/loading.interceptor';
// provideClientHydration()
import { KeycloakService } from './services/keycloak.service';
import { SelectOptionsService } from './services/select-options.service';
import { UserService } from './services/user.service';
// provideClientHydration()
export const appConfig: ApplicationConfig = {
providers: [
provideHttpClient(withInterceptorsFromDi()),
{provide:KeycloakService},
{ provide: KeycloakService },
{
provide: APP_INITIALIZER,
useFactory: initializeKeycloak,
@@ -28,23 +27,32 @@ export const appConfig: ApplicationConfig = {
deps: [SelectOptionsService],
},
{
provide:HTTP_INTERCEPTORS,
useClass:LoadingInterceptor,
multi:true
provide: HTTP_INTERCEPTORS,
useClass: LoadingInterceptor,
multi: true,
},
provideRouter(routes),provideAnimations(),
provideRouter(
routes,
withEnabledBlockingInitialNavigation(),
withInMemoryScrolling({
scrollPositionRestoration: 'enabled',
anchorScrolling: 'enabled',
}),
),
provideAnimations(),
// {provide: LOCALE_ID, useValue: 'en-US' }
]
],
};
function initUserService(userService:UserService) {
function initUserService(userService: UserService) {
return () => {
//selectOptions.init();
}
};
}
function initServices(selectOptions:SelectOptionsService) {
function initServices(selectOptions: SelectOptionsService) {
return () => {
selectOptions.init();
}
};
}
function initializeKeycloak(keycloak: KeycloakService) {
@@ -57,7 +65,7 @@ function initializeKeycloak(keycloak: KeycloakService) {
},
initOptions: {
onLoad: 'check-sso',
silentCheckSsoRedirectUri: (<any>window).location.origin + '/assets/silent-check-sso.html'
silentCheckSsoRedirectUri: (<any>window).location.origin + '/assets/silent-check-sso.html',
},
});
}
}