Add OtpDialogService for mobile-friendly OTP authentication dialog
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
using FrontOffice.Main.Utilities;
|
||||
using Microsoft.AspNetCore.Components;
|
||||
|
||||
namespace FrontOffice.Main.Pages.Profile;
|
||||
|
||||
public partial class Wallet : ComponentBase
|
||||
{
|
||||
[Inject] private WalletService WalletService { get; set; } = default!;
|
||||
|
||||
private (string Credit, string Network) _balances = ("-", "-");
|
||||
private List<WalletTransaction> _txs = new();
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
var b = await WalletService.GetBalancesAsync();
|
||||
_balances = (FormatPrice(b.CreditBalance), FormatPrice(b.NetworkBalance));
|
||||
_txs = await WalletService.GetTransactionsAsync();
|
||||
}
|
||||
|
||||
private static string FormatPrice(long price) => string.Format("{0:N0} تومان", price);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user