Interface: ScopedRbacDecorators<T, G>
Defined in: packages/nestjs/src/decorators.ts:158
The decorators of createRbacDecorators<T, G>() when T has per-guard names (RbacTypeConfig['guards']): like RbacDecorators, but the names are those of the guard each decorator checks in, its { guard } option or else G (the guard of the resolved subject, RbacModule's guard). @RequirePermissions('orders.read', { guard: 'api' }) takes the api names.
Type Parameters
| Type Parameter | Default type |
|---|---|
T extends RbacTypeConfig | - |
G extends string | DefaultGuardName<T> |
Properties
| Property | Type | Description | Defined in |
|---|---|---|---|
CanAll | <A>(...args) => <TFunction, Y>(target, propertyKey?, descriptor?) => void | RbacDecorators.CanAll, with the names of the guard it checks in. | packages/nestjs/src/decorators.ts:176 |
CanAny | <A>(...args) => <TFunction, Y>(target, propertyKey?, descriptor?) => void | RbacDecorators.CanAny, with the names of the guard it checks in. | packages/nestjs/src/decorators.ts:172 |
RequirePermissions | <A>(...args) => <TFunction, Y>(target, propertyKey?, descriptor?) => void | RbacDecorators.RequirePermissions, with the names of the guard it checks in. | packages/nestjs/src/decorators.ts:160 |
RequireRoleOrPermission | <A>(...args) => <TFunction, Y>(target, propertyKey?, descriptor?) => void | RbacDecorators.RequireRoleOrPermission, with the names of the guard it checks in. | packages/nestjs/src/decorators.ts:168 |
RequireRoles | <A>(...args) => <TFunction, Y>(target, propertyKey?, descriptor?) => void | RbacDecorators.RequireRoles, with the names of the guard it checks in. | packages/nestjs/src/decorators.ts:164 |
