fromJson static method
Inherited by: TonWalletTransactionTypeKeyChange TonWalletTransactionTypeNftTransfer TonWalletTransactionTypeOnRampDeposit TonWalletTransactionTypeTelegramGiftDelisting TonWalletTransactionTypeTelegramGiftListing TonWalletTransactionTypeTelegramGiftOfferAcceptance TonWalletTransactionTypeTelegramGiftOfferCancellation TonWalletTransactionTypeTelegramGiftOfferCreation TonWalletTransactionTypeTelegramGiftOfferDecline TonWalletTransactionTypeTelegramGiftOfferExpiration TonWalletTransactionTypeTelegramGiftPurchase TonWalletTransactionTypeTelegramGiftSale TonWalletTransactionTypeTelegramGiftTransfer TonWalletTransactionTypeTransfer
Implementation
static TonWalletTransactionTypeTelegramGiftSale? fromJson(
Map<String, dynamic>? json) {
if (json == null) {
return null;
}
return TonWalletTransactionTypeTelegramGiftSale(
nft: TonNft.fromJson(json['nft'] as Map<String, dynamic>?),
amount: (json['amount'] is int
? json['amount'] as int
: int.tryParse(json['amount']?.toString() ?? '')) ??
0,
);
}