Init Git
This commit is contained in:
@@ -0,0 +1,46 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using AMREZ.EOP.Contracts.DTOs.Tenancy.AddBaseDomain;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class AddBaseDomainUseCase : IAddBaseDomainUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
|
||||
public AddBaseDomainUseCase(ITenantResolver resolver, IHttpContextAccessor http, IUnitOfWork uow, ITenantRepository repo)
|
||||
{ _resolver = resolver; _http = http; _uow = uow; _repo = repo; }
|
||||
|
||||
public async Task<AddBaseDomainResponse?> ExecuteAsync(AddBaseDomainRequest request, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
|
||||
var ctx = _resolver.Resolve(http, hint: null);
|
||||
if (ctx is null) return null;
|
||||
|
||||
var baseDomain = (request.BaseDomain ?? string.Empty).Trim().TrimEnd('.').ToLowerInvariant();
|
||||
if (string.IsNullOrWhiteSpace(baseDomain)) return null;
|
||||
|
||||
await _uow.BeginAsync(ctx, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var ok = await _repo.AddBaseDomainAsync(baseDomain, ct); // repo ดึง target tenant จาก X-Tenant/context
|
||||
if (!ok) { await _uow.RollbackAsync(ct); return null; }
|
||||
|
||||
await _uow.CommitAsync(ct);
|
||||
return new AddBaseDomainResponse(baseDomain);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,77 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using AMREZ.EOP.Contracts.DTOs.Tenancy.CreateTenant;
|
||||
using AMREZ.EOP.Domain.Entities.Tenancy;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class CreateTenantUseCase : ICreateTenantUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
private readonly ITenantProvisioner _provisioner;
|
||||
|
||||
|
||||
public CreateTenantUseCase(
|
||||
ITenantResolver resolver,
|
||||
IHttpContextAccessor http,
|
||||
IUnitOfWork uow,
|
||||
ITenantRepository repo,
|
||||
ITenantProvisioner provisioner
|
||||
)
|
||||
{
|
||||
_resolver = resolver;
|
||||
_http = http;
|
||||
_uow = uow;
|
||||
_repo = repo;
|
||||
_provisioner = provisioner;
|
||||
}
|
||||
|
||||
public async Task<CreateTenantResponse?> ExecuteAsync(CreateTenantRequest request, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
var tenant = _resolver.Resolve(http, request);
|
||||
if (tenant is null) return null;
|
||||
|
||||
await _uow.BeginAsync(tenant, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var key = request.TenantKey.Trim().ToLowerInvariant();
|
||||
if (await _repo.TenantExistsAsync(key, ct))
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
return null;
|
||||
}
|
||||
|
||||
var row = new TenantConfig
|
||||
{
|
||||
TenantKey = key,
|
||||
Schema = string.IsNullOrWhiteSpace(request.Schema) ? null : request.Schema!.Trim(),
|
||||
ConnectionString = string.IsNullOrWhiteSpace(request.ConnectionString) ? null : request.ConnectionString!.Trim(),
|
||||
Mode = request.Mode,
|
||||
IsActive = request.IsActive,
|
||||
UpdatedAtUtc = DateTimeOffset.UtcNow
|
||||
};
|
||||
|
||||
var ok = await _repo.CreateAsync(row, ct);
|
||||
if (!ok) { await _uow.RollbackAsync(ct); return null; }
|
||||
|
||||
await _uow.CommitAsync(ct);
|
||||
|
||||
await _provisioner.ProvisionAsync(key, ct);
|
||||
|
||||
return new CreateTenantResponse(key);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class DeleteTenantUseCase : IDeleteTenantUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
|
||||
public DeleteTenantUseCase(ITenantResolver resolver, IHttpContextAccessor http, IUnitOfWork uow, ITenantRepository repo)
|
||||
{ _resolver = resolver; _http = http; _uow = uow; _repo = repo; }
|
||||
|
||||
public async Task<bool> ExecuteAsync(string tenantKey, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
var key = (tenantKey ?? string.Empty).Trim().ToLowerInvariant();
|
||||
if (string.IsNullOrWhiteSpace(key)) return false;
|
||||
|
||||
var ctx = _resolver.Resolve(http, hint: null);
|
||||
if (ctx is null) return false;
|
||||
|
||||
await _uow.BeginAsync(ctx, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var ok = await _repo.DeleteAsync(key, ct);
|
||||
if (!ok) { await _uow.RollbackAsync(ct); return false; }
|
||||
await _uow.CommitAsync(ct);
|
||||
return true;
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
45
AMREZ.EOP.Application/UseCases/Tenancy/ListDomainsUseCase.cs
Normal file
45
AMREZ.EOP.Application/UseCases/Tenancy/ListDomainsUseCase.cs
Normal file
@@ -0,0 +1,45 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using AMREZ.EOP.Contracts.DTOs.Tenancy.ListDomains;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class ListDomainsUseCase : IListDomainsUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
|
||||
public ListDomainsUseCase(ITenantResolver resolver, IHttpContextAccessor http, IUnitOfWork uow, ITenantRepository repo)
|
||||
{ _resolver = resolver; _http = http; _uow = uow; _repo = repo; }
|
||||
|
||||
public async Task<ListDomainsResponse?> ExecuteAsync(ListDomainsRequest request, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
var key = string.IsNullOrWhiteSpace(request?.TenantKey) ? null : request!.TenantKey!.Trim().ToLowerInvariant();
|
||||
|
||||
var ctx = _resolver.Resolve(http, hint: null);
|
||||
if (ctx is null) return null;
|
||||
|
||||
await _uow.BeginAsync(ctx, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var items = (await _repo.ListDomainsAsync(key, ct))
|
||||
.Select(x => new DomainDto(x.Domain, x.TenantKey, x.IsPlatformBaseDomain, x.IsActive, x.UpdatedAtUtc))
|
||||
.ToList();
|
||||
|
||||
await _uow.CommitAsync(ct);
|
||||
return new ListDomainsResponse(items);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
43
AMREZ.EOP.Application/UseCases/Tenancy/ListTenantsUseCase.cs
Normal file
43
AMREZ.EOP.Application/UseCases/Tenancy/ListTenantsUseCase.cs
Normal file
@@ -0,0 +1,43 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using AMREZ.EOP.Contracts.DTOs.Tenancy.ListTenants;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class ListTenantsUseCase : IListTenantsUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
|
||||
public ListTenantsUseCase(ITenantResolver resolver, IHttpContextAccessor http, IUnitOfWork uow, ITenantRepository repo)
|
||||
{ _resolver = resolver; _http = http; _uow = uow; _repo = repo; }
|
||||
|
||||
public async Task<ListTenantsResponse?> ExecuteAsync(ListTenantsRequest request, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
var ctx = _resolver.Resolve(http, hint: null);
|
||||
if (ctx is null) return null;
|
||||
|
||||
await _uow.BeginAsync(ctx, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var items = (await _repo.ListTenantsAsync(ct))
|
||||
.Select(x => new TenantDto(x.TenantKey, x.Schema, x.ConnectionString, x.Mode, x.IsActive, x.UpdatedAtUtc))
|
||||
.ToList();
|
||||
|
||||
await _uow.CommitAsync(ct);
|
||||
return new ListTenantsResponse(items);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
47
AMREZ.EOP.Application/UseCases/Tenancy/MapDomainUseCase.cs
Normal file
47
AMREZ.EOP.Application/UseCases/Tenancy/MapDomainUseCase.cs
Normal file
@@ -0,0 +1,47 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using AMREZ.EOP.Contracts.DTOs.Tenancy.MapDomain;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class MapDomainUseCase : IMapDomainUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
|
||||
public MapDomainUseCase(ITenantResolver resolver, IHttpContextAccessor http, IUnitOfWork uow, ITenantRepository repo)
|
||||
{ _resolver = resolver; _http = http; _uow = uow; _repo = repo; }
|
||||
|
||||
public async Task<MapDomainResponse?> ExecuteAsync(MapDomainRequest request, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
|
||||
var key = string.IsNullOrWhiteSpace(request?.TenantKey) ? null : request!.TenantKey!.Trim().ToLowerInvariant();
|
||||
var domain = (request?.Domain ?? string.Empty).Trim().TrimEnd('.').ToLowerInvariant();
|
||||
if (string.IsNullOrWhiteSpace(domain)) return null;
|
||||
|
||||
var ctx = _resolver.Resolve(http, hint: null);
|
||||
if (ctx is null) return null;
|
||||
|
||||
await _uow.BeginAsync(ctx, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var ok = await _repo.MapDomainAsync(domain, key, ct);
|
||||
if (!ok) { await _uow.RollbackAsync(ct); return null; }
|
||||
|
||||
await _uow.CommitAsync(ct);
|
||||
return new MapDomainResponse(domain, key);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using AMREZ.EOP.Contracts.DTOs.Tenancy.RemoveBaseDomain;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class RemoveBaseDomainUseCase : IRemoveBaseDomainUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
|
||||
public RemoveBaseDomainUseCase(ITenantResolver resolver, IHttpContextAccessor http, IUnitOfWork uow, ITenantRepository repo)
|
||||
{ _resolver = resolver; _http = http; _uow = uow; _repo = repo; }
|
||||
|
||||
public async Task<RemoveBaseDomainResponse?> ExecuteAsync(RemoveBaseDomainRequest request, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
|
||||
var key = string.IsNullOrWhiteSpace(request?.TenantKey) ? null : request!.TenantKey!.Trim().ToLowerInvariant();
|
||||
var baseDomain = (request?.BaseDomain ?? string.Empty).Trim().TrimEnd('.').ToLowerInvariant();
|
||||
if (string.IsNullOrWhiteSpace(baseDomain)) return null;
|
||||
|
||||
var ctx = _resolver.Resolve(http, hint: null);
|
||||
if (ctx is null) return null;
|
||||
|
||||
await _uow.BeginAsync(ctx, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var ok = await _repo.RemoveBaseDomainAsync(baseDomain, ct);
|
||||
if (!ok) { await _uow.RollbackAsync(ct); return null; }
|
||||
|
||||
await _uow.CommitAsync(ct);
|
||||
return new RemoveBaseDomainResponse(baseDomain);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
47
AMREZ.EOP.Application/UseCases/Tenancy/UnmapDomainUseCase.cs
Normal file
47
AMREZ.EOP.Application/UseCases/Tenancy/UnmapDomainUseCase.cs
Normal file
@@ -0,0 +1,47 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using AMREZ.EOP.Contracts.DTOs.Tenancy.UnmapDomain;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class UnmapDomainUseCase : IUnmapDomainUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
|
||||
public UnmapDomainUseCase(ITenantResolver resolver, IHttpContextAccessor http, IUnitOfWork uow, ITenantRepository repo)
|
||||
{ _resolver = resolver; _http = http; _uow = uow; _repo = repo; }
|
||||
|
||||
public async Task<UnmapDomainResponse?> ExecuteAsync(UnmapDomainRequest request, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
|
||||
var key = string.IsNullOrWhiteSpace(request?.TenantKey) ? null : request!.TenantKey!.Trim().ToLowerInvariant();
|
||||
var domain = (request?.Domain ?? string.Empty).Trim().TrimEnd('.').ToLowerInvariant();
|
||||
if (string.IsNullOrWhiteSpace(domain)) return null;
|
||||
|
||||
var ctx = _resolver.Resolve(http, hint: null);
|
||||
if (ctx is null) return null;
|
||||
|
||||
await _uow.BeginAsync(ctx, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var ok = await _repo.UnmapDomainAsync(domain, ct);
|
||||
if (!ok) { await _uow.RollbackAsync(ct); return null; }
|
||||
|
||||
await _uow.CommitAsync(ct);
|
||||
return new UnmapDomainResponse(domain);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,58 @@
|
||||
using System.Data;
|
||||
using AMREZ.EOP.Abstractions.Applications.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Applications.UseCases.Tenancy;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Common;
|
||||
using AMREZ.EOP.Abstractions.Infrastructures.Repositories;
|
||||
using AMREZ.EOP.Contracts.DTOs.Tenancy.UpdateTenant;
|
||||
using Microsoft.AspNetCore.Http;
|
||||
|
||||
namespace AMREZ.EOP.Application.UseCases.Tenancy;
|
||||
|
||||
public sealed class UpdateTenantUseCase : IUpdateTenantUseCase
|
||||
{
|
||||
private readonly ITenantResolver _resolver;
|
||||
private readonly IHttpContextAccessor _http;
|
||||
private readonly IUnitOfWork _uow;
|
||||
private readonly ITenantRepository _repo;
|
||||
|
||||
public UpdateTenantUseCase(ITenantResolver resolver, IHttpContextAccessor http, IUnitOfWork uow, ITenantRepository repo)
|
||||
{ _resolver = resolver; _http = http; _uow = uow; _repo = repo; }
|
||||
|
||||
public async Task<UpdateTenantResponse?> ExecuteAsync(UpdateTenantRequest request, CancellationToken ct = default)
|
||||
{
|
||||
var http = _http.HttpContext ?? throw new InvalidOperationException("No HttpContext");
|
||||
|
||||
var key = (request?.TenantKey ?? string.Empty).Trim().ToLowerInvariant();
|
||||
if (string.IsNullOrWhiteSpace(key)) return null;
|
||||
|
||||
var ctx = _resolver.Resolve(http, hint: null);
|
||||
if (ctx is null) return null;
|
||||
|
||||
await _uow.BeginAsync(ctx, IsolationLevel.ReadCommitted, ct);
|
||||
try
|
||||
{
|
||||
var current = await _repo.GetAsync(key, ct);
|
||||
if (current is null) { await _uow.RollbackAsync(ct); return null; } // 404
|
||||
|
||||
if (request!.IfUnmodifiedSince.HasValue && current.UpdatedAtUtc > request.IfUnmodifiedSince.Value)
|
||||
{ await _uow.RollbackAsync(ct); return null; } // 412
|
||||
|
||||
current.Schema = request.Schema is null ? current.Schema : (string.IsNullOrWhiteSpace(request.Schema) ? null : request.Schema.Trim());
|
||||
current.ConnectionString = request.ConnectionString is null ? current.ConnectionString : (string.IsNullOrWhiteSpace(request.ConnectionString) ? null : request.ConnectionString.Trim());
|
||||
if (request.Mode.HasValue) current.Mode = request.Mode.Value;
|
||||
if (request.IsActive.HasValue) current.IsActive = request.IsActive.Value;
|
||||
current.UpdatedAtUtc = DateTimeOffset.UtcNow;
|
||||
|
||||
var ok = await _repo.UpdateAsync(current, request.IfUnmodifiedSince, ct);
|
||||
if (!ok) { await _uow.RollbackAsync(ct); return null; }
|
||||
|
||||
await _uow.CommitAsync(ct);
|
||||
return new UpdateTenantResponse(current.TenantKey, current.UpdatedAtUtc);
|
||||
}
|
||||
catch
|
||||
{
|
||||
await _uow.RollbackAsync(ct);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user