feat: ClubMembershipCycle IHasHistory + PackageId in WalletHistory (F1)
Build and Deploy to Kubernetes / build-and-deploy (push) Successful in 8m33s
Build and Deploy to Kubernetes / build-and-deploy (push) Successful in 8m33s
- ClubMembershipCycle now implements IHasHistory<ClubMembershipCycleHistory> - CreateHistorySnapshot: New* fields from current state, Old* auto-filled by interceptor - Parses action string to ClubMembershipCycleAction enum - Add PackageId to 6 UserWalletHistory creation sites (F1 fix): - VerifyPackagePurchaseCommandHandler: balanceLog + discountLog (order.PackageId) - CheckAndProcessDayaLoansCommandHandler: mainLog + discountLog (package.Id) - CreateManualPaymentCommandHandler: walletLog (package.Id) - PackageService.CustomerVerifyPackagePurchase: walletLog (purchase.PackageId) - Non-package flows (orders, commissions, manual) correctly keep PackageId=null
This commit is contained in:
+4
-2
@@ -139,7 +139,8 @@ public class VerifyPackagePurchaseCommandHandler
|
||||
CurrentDiscountBalance = wallet.DiscountBalance - discountAmount, // قبل از شارژ DiscountBalance
|
||||
ChangeDiscountValue = 0,
|
||||
IsIncrease = true,
|
||||
RefrenceId = transaction.Id
|
||||
RefrenceId = transaction.Id,
|
||||
PackageId = order.PackageId
|
||||
};
|
||||
await _context.UserWalletHistories.AddAsync(balanceLog, cancellationToken);
|
||||
|
||||
@@ -154,7 +155,8 @@ public class VerifyPackagePurchaseCommandHandler
|
||||
CurrentDiscountBalance = wallet.DiscountBalance,
|
||||
ChangeDiscountValue = discountAmount,
|
||||
IsIncrease = true,
|
||||
RefrenceId = transaction.Id
|
||||
RefrenceId = transaction.Id,
|
||||
PackageId = order.PackageId
|
||||
};
|
||||
await _context.UserWalletHistories.AddAsync(discountLog, cancellationToken);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user