diff options
Diffstat (limited to 'ui/app/components/tx-list.js')
-rw-r--r-- | ui/app/components/tx-list.js | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/ui/app/components/tx-list.js b/ui/app/components/tx-list.js index a02849d0e..70722f43e 100644 --- a/ui/app/components/tx-list.js +++ b/ui/app/components/tx-list.js @@ -6,9 +6,10 @@ const prefixForNetwork = require('../../lib/etherscan-prefix-for-network') const selectors = require('../selectors') const TxListItem = require('./tx-list-item') const ShiftListItem = require('./shift-list-item') -const { formatBalance, formatDate } = require('../util') +const { formatDate } = require('../util') const { showConfTxPage } = require('../actions') const classnames = require('classnames') +const { tokenInfoGetter } = require('../token-util') module.exports = connect(mapStateToProps, mapDispatchToProps)(TxList) @@ -21,7 +22,7 @@ function mapStateToProps (state) { function mapDispatchToProps (dispatch) { return { - showConfTxPage: ({ id }) => dispatch(showConfTxPage({ id })) + showConfTxPage: ({ id }) => dispatch(showConfTxPage({ id })), } } @@ -30,10 +31,11 @@ function TxList () { Component.call(this) } -TxList.prototype.render = function () { - - const { txsToRender, showConfTxPage } = this.props +TxList.prototype.componentWillMount = function () { + this.tokenInfoGetter = tokenInfoGetter() +} +TxList.prototype.render = function () { return h('div.flex-column.tx-list-container', {}, [ h('div.flex-row.tx-list-header-wrapper', [ @@ -93,15 +95,15 @@ TxList.prototype.renderTransactionListItem = function (transaction, conversionRa txParams: transaction.txParams, transactionStatus, transActionId, - key: transActionId, dateString, address, transactionAmount, transactionHash, conversionRate, + tokenInfoGetter: this.tokenInfoGetter, } - const isUnapproved = transactionStatus === 'unapproved'; + const isUnapproved = transactionStatus === 'unapproved' if (isUnapproved) { opts.onClick = () => showConfTxPage({id: transActionId}) |