This commit is contained in:
wanyongkang
2020-11-26 18:23:31 +08:00
parent 539205f9cb
commit 0f1dcf1ce3

View File

@@ -541,7 +541,7 @@ FROM product_order where {where} GROUP BY Channel,ProductName order by Channel,
accountEntity.ChargeStatus = AccountChargeStatus.Exception;
accountEntity.Remark = ret.Message;
await m_ProductAccountService.Update(accountEntity);
accountError += $"{accountEntity.Account}{accountEntity.Remark}," + ret.Message;
accountError += $"{accountEntity.Account}{accountEntity.Remark},";
}
else if (ret.Data != null && ret.Data.ToString().Has())
{
@@ -758,7 +758,7 @@ FROM product_order where {where} GROUP BY Channel,ProductName order by Channel,
var refundDayPrice = userPrice != null && userPrice.RefundDayPrice > 0 ? userPrice.RefundDayPrice : product.RefundDayPrice;
var lastOrder = await GetLastOrderByAccount(account);
//获取使用天数
var useDay = (int)Math.Ceiling((DateTime.Now - lastOrder.UpdateTime).TotalDays);
var refundAmount = lastOrder.PaymentAmount / lastOrder.AccountCount - useDay * refundDayPrice.Value * accountInfo.ConnectCount;
refundAmount = refundAmount <= 0 ? 0 : refundAmount;
@@ -777,7 +777,7 @@ FROM product_order where {where} GROUP BY Channel,ProductName order by Channel,
PayType = PayType.None,
UserId = userId,
UserName = accountInfo.UserCode,
DayCount = (accountInfo.EndTime - DateTime.Now).Value.Days,
DayCount = (lastOrder.EndTime - DateTime.Now).Value.Days,
DayPrice = refundDayPrice,
Accounts = account,
PaymentAmount = lastOrder.PaymentAmount/ lastOrder.AccountCount,