fix: allow super admin tenant-scoped role ops
This commit is contained in:
@@ -17,7 +17,7 @@ public sealed class UpdateRoleCommandHandler(
|
||||
public async Task<RoleDto?> Handle(UpdateRoleCommand request, CancellationToken cancellationToken)
|
||||
{
|
||||
// 1. 获取租户上下文并查询角色
|
||||
var tenantId = tenantProvider.GetCurrentTenantId();
|
||||
var tenantId = request.TenantId ?? tenantProvider.GetCurrentTenantId();
|
||||
var role = await roleRepository.FindByIdAsync(request.RoleId, tenantId, cancellationToken);
|
||||
if (role == null)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user