RED-6523 - ui multitenancy links

This commit is contained in:
Timo Bejan 2023-04-05 16:20:48 +03:00
parent 97470bb723
commit 6c63f851cf

View File

@ -9,7 +9,10 @@ import { TenantContextHolder } from './services';
export class TenantPipe implements PipeTransform {
readonly #tenant = inject(TenantContextHolder);
transform(value: string | string[]): string {
transform(value: string | string[]): string | undefined {
if (!value) {
return undefined;
}
const _value = Array.isArray(value) ? value.join('/') : value;
return '/' + this.#tenant.currentTenant + _value;
}