feat:补齐商户版本号
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
using MediatR;
|
||||
using Microsoft.Extensions.Logging;
|
||||
using System.Security.Cryptography;
|
||||
using TakeoutSaaS.Application.App.Merchants.Commands;
|
||||
using TakeoutSaaS.Application.App.Merchants.Dto;
|
||||
using TakeoutSaaS.Domain.Merchants.Entities;
|
||||
@@ -26,6 +27,7 @@ public sealed class CreateMerchantCommandHandler(IMerchantRepository merchantRep
|
||||
ContactPhone = request.ContactPhone.Trim(),
|
||||
ContactEmail = request.ContactEmail?.Trim(),
|
||||
Status = request.Status,
|
||||
RowVersion = RandomNumberGenerator.GetBytes(16),
|
||||
JoinedAt = DateTime.UtcNow
|
||||
};
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using MediatR;
|
||||
using System.Security.Cryptography;
|
||||
using TakeoutSaaS.Application.App.Tenants.Commands;
|
||||
using TakeoutSaaS.Application.App.Tenants.Dto;
|
||||
using TakeoutSaaS.Domain.Merchants.Entities;
|
||||
@@ -130,7 +131,8 @@ public sealed class ReviewTenantCommandHandler(
|
||||
JoinedAt = now,
|
||||
LastReviewedAt = now,
|
||||
LastReviewedBy = currentUserAccessor.UserId == 0 ? null : currentUserAccessor.UserId,
|
||||
IsFrozen = false
|
||||
IsFrozen = false,
|
||||
RowVersion = RandomNumberGenerator.GetBytes(16)
|
||||
};
|
||||
|
||||
await merchantRepository.AddMerchantAsync(merchant, cancellationToken);
|
||||
|
||||
Reference in New Issue
Block a user