chore: add documentation comments and stylecop rules

This commit is contained in:
2025-12-04 11:25:01 +08:00
parent 17d143a351
commit 8e4c2b0e45
142 changed files with 1309 additions and 439 deletions

View File

@@ -15,8 +15,6 @@ namespace TakeoutSaaS.Infrastructure.App.Repositories;
/// </remarks>
public sealed class EfDeliveryRepository(TakeoutAppDbContext context) : IDeliveryRepository
{
/// <inheritdoc />
public Task<DeliveryOrder?> FindByIdAsync(long deliveryOrderId, long tenantId, CancellationToken cancellationToken = default)
{

View File

@@ -15,8 +15,6 @@ namespace TakeoutSaaS.Infrastructure.App.Repositories;
/// </remarks>
public sealed class EfMerchantRepository(TakeoutAppDbContext context) : IMerchantRepository
{
/// <inheritdoc />
public Task<Merchant?> FindByIdAsync(long merchantId, long tenantId, CancellationToken cancellationToken = default)
{

View File

@@ -16,8 +16,6 @@ namespace TakeoutSaaS.Infrastructure.App.Repositories;
/// </remarks>
public sealed class EfOrderRepository(TakeoutAppDbContext context) : IOrderRepository
{
/// <inheritdoc />
public Task<Order?> FindByIdAsync(long orderId, long tenantId, CancellationToken cancellationToken = default)
{

View File

@@ -15,8 +15,6 @@ namespace TakeoutSaaS.Infrastructure.App.Repositories;
/// </remarks>
public sealed class EfPaymentRepository(TakeoutAppDbContext context) : IPaymentRepository
{
/// <inheritdoc />
public Task<PaymentRecord?> FindByIdAsync(long paymentId, long tenantId, CancellationToken cancellationToken = default)
{

View File

@@ -15,8 +15,6 @@ namespace TakeoutSaaS.Infrastructure.App.Repositories;
/// </remarks>
public sealed class EfProductRepository(TakeoutAppDbContext context) : IProductRepository
{
/// <inheritdoc />
public Task<Product?> FindByIdAsync(long productId, long tenantId, CancellationToken cancellationToken = default)
{

View File

@@ -15,8 +15,6 @@ namespace TakeoutSaaS.Infrastructure.App.Repositories;
/// </remarks>
public sealed class EfStoreRepository(TakeoutAppDbContext context) : IStoreRepository
{
/// <inheritdoc />
public Task<Store?> FindByIdAsync(long storeId, long tenantId, CancellationToken cancellationToken = default)
{

View File

@@ -12,7 +12,6 @@ namespace TakeoutSaaS.Infrastructure.Dictionary.Repositories;
/// </summary>
public sealed class EfDictionaryRepository(DictionaryDbContext context) : IDictionaryRepository
{
public Task<DictionaryGroup?> FindGroupByIdAsync(long id, CancellationToken cancellationToken = default)
=> context.DictionaryGroups.FirstOrDefaultAsync(group => group.Id == id, cancellationToken);

View File

@@ -13,7 +13,6 @@ namespace TakeoutSaaS.Infrastructure.Identity.Persistence;
/// </summary>
public sealed class EfIdentityUserRepository(IdentityDbContext dbContext) : IIdentityUserRepository
{
public Task<IdentityUser?> FindByAccountAsync(string account, CancellationToken cancellationToken = default)
=> dbContext.IdentityUsers.AsNoTracking().FirstOrDefaultAsync(x => x.Account == account, cancellationToken);

View File

@@ -12,7 +12,6 @@ namespace TakeoutSaaS.Infrastructure.Identity.Persistence;
/// </summary>
public sealed class EfMiniUserRepository(IdentityDbContext dbContext) : IMiniUserRepository
{
public Task<MiniUser?> FindByOpenIdAsync(string openId, CancellationToken cancellationToken = default)
=> dbContext.MiniUsers.AsNoTracking().FirstOrDefaultAsync(x => x.OpenId == openId, cancellationToken);