refactor: ( iam ) remove user relations

This commit is contained in:
Abubeker Yasin
2026-06-22 15:01:16 +03:00
parent a63b49d419
commit 4b3c47ca03
9 changed files with 92 additions and 39 deletions

View File

@@ -1,7 +1 @@
// Thin adapter: re-exports IAM guard and a stub IamRoles decorator so that
// controllers written against the forthcoming IamGuard compile today.
export { JwtGuard as IamGuard } from '@tria-plc/api-common/modules/auth/services/jwt.guard';
export function IamRoles(..._roles: string[]) {
return function (_target: any, _key?: any, _descriptor?: any) {};
}

View File

@@ -1,5 +1,4 @@
import { SetMetadata } from '@nestjs/common';
import { UserRole } from '@prisma/client';
export const ROLES_KEY = 'roles';
export const Roles = (...roles: UserRole[]) => SetMetadata(ROLES_KEY, roles);
export const Roles = (...roles: string[]) => SetMetadata(ROLES_KEY, roles);