1
0
mirror of https://github.com/xuthus83/pigallery2.git synced 2025-01-14 14:43:17 +08:00
pigallery2/src/frontend/app/pipes/StringifyRolePipe.ts
2022-04-14 14:36:56 +02:00

11 lines
274 B
TypeScript

import { Pipe, PipeTransform } from '@angular/core';
import { UserRoles } from '../../../common/entities/UserDTO';
@Pipe({ name: 'stringifyRole' })
export class StringifyRole implements PipeTransform {
transform(role: number): string {
return UserRoles[role];
}
}