CW- 463 Fix transaction receive address not showing for Eth/Erc20 (#1076)

* Fix transaction receive address not showing for Eth/Erc20 [skip ci]

* Fix transaction receive address for Eth/Erc20
This commit is contained in:
Omar Hatem 2023-09-14 22:12:41 +03:00 committed by GitHub
parent 4bcf6162f1
commit 4c9c6a1eae
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 9 additions and 1 deletions

View file

@ -14,6 +14,7 @@ class EthereumTransactionInfo extends TransactionInfo {
required this.isPending,
required this.date,
required this.confirmations,
required this.to,
}) : this.amount = ethAmount.toInt(),
this.fee = ethFee.toInt();
@ -30,6 +31,7 @@ class EthereumTransactionInfo extends TransactionInfo {
final int confirmations;
final String tokenSymbol;
String? _fiatAmount;
final String? to;
@override
String amountFormatted() =>
@ -56,6 +58,7 @@ class EthereumTransactionInfo extends TransactionInfo {
isPending: data['isPending'] as bool,
confirmations: data['confirmations'] as int,
tokenSymbol: data['tokenSymbol'] as String,
to: data['to'],
);
}
@ -70,5 +73,6 @@ class EthereumTransactionInfo extends TransactionInfo {
'isPending': isPending,
'confirmations': confirmations,
'tokenSymbol': tokenSymbol,
'to': to,
};
}

View file

@ -283,6 +283,7 @@ abstract class EthereumWalletBase
ethFee: BigInt.from(transactionModel.gasUsed) * transactionModel.gasPrice,
exponent: transactionModel.tokenDecimal ?? 18,
tokenSymbol: transactionModel.tokenSymbol ?? "ETH",
to: transactionModel.to,
);
}