feat: Implement Magic Wallet functionality
Build and Deploy to Kubernetes / build-and-deploy (push) Successful in 8m36s
Build and Deploy to Kubernetes / build-and-deploy (push) Successful in 8m36s
- Added ClubMembershipCycle entity and DbSet to IApplicationDbContext. - Updated VAT rate from 9% to 10% in VatCalculator and related areas. - Introduced Magic Wallet settings in SystemConstants. - Enhanced UserWallet entity to support Magic Wallet features. - Updated TransactionType enum to include Magic Wallet transactions. - Configured UserWallet to handle Magic Wallet properties in ApplicationDbContext. - Implemented OrmCommissionCalculationStrategy to exclude Magic Wallet users from commission calculations. - Added Protobuf definitions for Magic Wallet methods and responses. - Created PaymentCallbackController endpoint for handling Magic Wallet charge callbacks. - Updated UserOrderService to manage Magic Wallet state transitions. - Developed UserWalletService to support Magic Wallet operations. - Created ChargeMagicWalletCommand and its handler for initiating Magic Wallet charges. - Implemented VerifyMagicWalletChargeCommand and handler for payment verification. - Added validation for ChargeMagicWalletCommand. - Established ClubMembershipCycle configuration for EF Core. - Introduced WalletMode enum to differentiate between Normal and Magic modes.
This commit is contained in:
@@ -92,6 +92,25 @@ public static class SystemConstants
|
||||
|
||||
#endregion
|
||||
|
||||
#region Magic Wallet Settings
|
||||
|
||||
/// <summary>
|
||||
/// ضریب شارژ کیفپول جادویی — واریز × 2.5 = اعتبار
|
||||
/// </summary>
|
||||
public const decimal MagicWalletMultiplier = 2.5m;
|
||||
|
||||
/// <summary>
|
||||
/// سقف واریز در هر دور جادویی (ریال) — 100M تومان
|
||||
/// </summary>
|
||||
public const long MagicWalletMaxDeposit = 1_000_000_000;
|
||||
|
||||
/// <summary>
|
||||
/// سقف اعتبار در هر دور جادویی (ریال) — 250M تومان
|
||||
/// </summary>
|
||||
public const long MagicWalletMaxCredit = 2_500_000_000;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Shop Settings
|
||||
|
||||
/// <summary>
|
||||
@@ -134,6 +153,11 @@ public static class SystemConstants
|
||||
["System.MaintenanceMode"] = SystemMaintenanceMode,
|
||||
["System.EnableAuditLog"] = SystemEnableAuditLog,
|
||||
|
||||
// Magic Wallet
|
||||
["MagicWallet.Multiplier"] = MagicWalletMultiplier,
|
||||
["MagicWallet.MaxDeposit"] = MagicWalletMaxDeposit,
|
||||
["MagicWallet.MaxCredit"] = MagicWalletMaxCredit,
|
||||
|
||||
// Shop
|
||||
["Shop.VAT"] = ShopVAT,
|
||||
["Shop.VATEnabled"] = ShopVATEnabled
|
||||
@@ -166,6 +190,11 @@ public static class SystemConstants
|
||||
("System.MaintenanceMode", SystemMaintenanceMode, "حالت تعمیر و نگهداری سیستم"),
|
||||
("System.EnableAuditLog", SystemEnableAuditLog, "فعالسازی لاگ تغییرات"),
|
||||
|
||||
// Magic Wallet
|
||||
("MagicWallet.Multiplier", MagicWalletMultiplier, "ضریب شارژ کیفپول جادویی (×2.5)"),
|
||||
("MagicWallet.MaxDeposit", MagicWalletMaxDeposit, "سقف واریز هر دور جادویی (ریال)"),
|
||||
("MagicWallet.MaxCredit", MagicWalletMaxCredit, "سقف اعتبار هر دور جادویی (ریال)"),
|
||||
|
||||
// Shop
|
||||
("Shop.VAT", ShopVAT, "مالیات بر ارزش افزوده"),
|
||||
("Shop.VATEnabled", ShopVATEnabled, "مالیات فعال است؟")
|
||||
|
||||
Reference in New Issue
Block a user