Merge branch 'dmp-refactoring' into accessibility-refactor

This commit is contained in:
mchouliara 2024-09-30 14:56:46 +03:00
commit f87d47e72e
1 changed files with 5 additions and 4 deletions

View File

@ -355,12 +355,13 @@ export class UserProfileComponent extends BaseComponent implements OnInit, OnDes
}
switchTenant(): void {
if (this.tenantFormGroup.valid === false) return;
const selectedTenant = this.tenantFormGroup.get('tenantCode').value;
this.authService.selectedTenant(selectedTenant.value);
window.location.href = this.tenantHandlingService.getCurrentUrlEnrichedWithTenantCode(selectedTenant.value, true);
if (!this.tenantFormGroup.valid || !selectedTenant) return;
this.authService.selectedTenant(selectedTenant);
window.location.href = this.tenantHandlingService.getCurrentUrlEnrichedWithTenantCode(selectedTenant, true);
}
//Preferences