fix payAt on payment , add version 0.27.36.58

release
Amir Hossein Khademi 2024-05-17 22:07:54 +03:30
parent f28e36e84e
commit 8dfbc108f6
3 changed files with 6 additions and 4 deletions

View File

@ -1 +1 @@
0.27.35.57
0.27.36.58

View File

@ -8,7 +8,7 @@ string env = builder.Environment.IsDevelopment() == true ? "Development" : "Prod
builder.Host.UseContentRoot(Directory.GetCurrentDirectory());
if (builder.Environment.IsDevelopment())
{
string projectName = "Hamyan";
string projectName = "Vesmeh";
builder.Configuration.AddJsonFile($"AppSettings/appsettings.json").AddJsonFile($"AppSettings/appsettings.{env}{projectName}.json");
}

View File

@ -24,6 +24,8 @@ public class CreateOrUpdatePaymentCommandHandler : IRequestHandler<CreateOrUpdat
var newEnt = Payment.Create(request.FactorNumber, request.Amount, request.Description, request.TransactionCode,
request.CardPan, request.Authority, request.Type, request.Status, request.OrderId, request.UserId);
newEnt.Id = ent.Id;
newEnt.CreatedAt = ent.CreatedAt == DateTime.MinValue ? DateTime.Now : ent.CreatedAt;
newEnt.CreatedBy = ent.CreatedBy;
_repositoryWrapper.SetRepository<Payment>()
.Update(newEnt);
@ -40,9 +42,9 @@ public class CreateOrUpdatePaymentCommandHandler : IRequestHandler<CreateOrUpdat
var newEnt = Payment.Create(request.FactorNumber, request.Amount, request.Description, request.TransactionCode,
request.CardPan, request.Authority, request.Type, request.Status, request.OrderId, request.UserId);
newEnt.Id = orderPayment.Id;
newEnt.CreatedAt = orderPayment.CreatedAt;
newEnt.CreatedAt = orderPayment.CreatedAt == DateTime.MinValue ? DateTime.Now : orderPayment.CreatedAt;
newEnt.CreatedBy = orderPayment.CreatedBy;
_repositoryWrapper.SetRepository<Payment>()
.Update(newEnt);