diff --git a/lib/application/pool/dex_pool_tx_list.dart b/lib/application/pool/dex_pool_tx_list.dart index c8acfec4..3a110230 100644 --- a/lib/application/pool/dex_pool_tx_list.dart +++ b/lib/application/pool/dex_pool_tx_list.dart @@ -67,6 +67,7 @@ Future> _getPoolTxList( DexToken? token1; DexToken? token2; DexActionType? typeTx; + String? addressAccount; switch (transactionAction.data!.actionRecipients[0].action) { case 'swap': for (final transactionMovement in transactionAction @@ -113,6 +114,7 @@ Future> _getPoolTxList( transactionMovement.amount, ).toDouble(); token2 = pool.pair.token1; + addressAccount = transactionMovement.to; } if ((transactionMovement.tokenAddress != null && @@ -124,6 +126,7 @@ Future> _getPoolTxList( transactionMovement.amount, ).toDouble(); token2 = pool.pair.token2; + addressAccount = transactionMovement.to; } } } @@ -157,7 +160,8 @@ Future> _getPoolTxList( token2 = pool.pair.token2; } } - + addressAccount = transaction + .validationStamp!.ledgerOperations!.transactionMovements[0].to; typeTx = DexActionType.removeLiquidity; break; case 'add_liquidity': @@ -188,7 +192,8 @@ Future> _getPoolTxList( token2 = pool.pair.token2; } } - + addressAccount = transaction + .validationStamp!.ledgerOperations!.transactionMovements[0].to; typeTx = DexActionType.addLiquidity; break; default: @@ -198,6 +203,7 @@ Future> _getPoolTxList( if (totalValueToken1 != null) { swapValue = totalValueToken1; } + dexPoolTxList.add( DexPoolTx( addressTx: transaction.address!.address, @@ -205,8 +211,7 @@ Future> _getPoolTxList( time: DateTime.fromMillisecondsSinceEpoch( transaction.validationStamp!.timestamp! * 1000, ), - addressAccount: transaction.validationStamp!.ledgerOperations! - .transactionMovements[0].to, + addressAccount: addressAccount, token1Amount: token1Amount, token2Amount: token2Amount, token1: token1, diff --git a/lib/ui/views/pool_tx_list/layouts/components/pool_tx_single.dart b/lib/ui/views/pool_tx_list/layouts/components/pool_tx_single.dart index 896c97f5..f43362c3 100644 --- a/lib/ui/views/pool_tx_list/layouts/components/pool_tx_single.dart +++ b/lib/ui/views/pool_tx_list/layouts/components/pool_tx_single.dart @@ -8,6 +8,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_gen/gen_l10n/localizations.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; import 'package:gradient_borders/box_borders/gradient_box_border.dart'; +import 'package:intl/intl.dart'; import 'package:timeago/timeago.dart' as timeago; class PoolListSingle extends ConsumerWidget { @@ -75,9 +76,16 @@ class PoolListSingle extends ConsumerWidget { : '${dexPoolTx.typeTx!.getLabel(context)} ', style: style, ), - SelectableText( - timeago.format(dexPoolTx.time!), - style: style, + Tooltip( + message: DateFormat( + 'yyyy-MM-dd HH:mm:ss', + ).format( + dexPoolTx.time!, + ), + child: SelectableText( + timeago.format(dexPoolTx.time!), + style: style, + ), ), ], ), diff --git a/pubspec.yaml b/pubspec.yaml index 7b3406bd..803cacb3 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -2,7 +2,7 @@ name: aedex description: Enable direct peer-to-peer trading of digital assets on the Archethic blockchain, eliminating the need for centralized intermediaries. publish_to: "none" -version: 2.3.2+94 +version: 2.3.3+95 environment: sdk: ">=3.3.0 <4.0.0"