-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Transaction Details to the Transaction List view #5182
Conversation
alextsg
commented
Aug 31, 2018
7fdc2a3
to
debffb0
Compare
@@ -0,0 +1,26 @@ | |||
import React from 'react' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just noticed that we have been using different naming conventions for test files. I've been doing name-component.test.js
for the test file corresponding to name.component.js
... I think I like yours better.
numberOfDecimals: 6, | ||
}) | ||
export function getEthConversionFromWeiHex ({ value, conversionRate, numberOfDecimals = 6 }) { | ||
const denominations = [ETH, GWEI, WEI] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I am reading this right, it is to ensure that the activity log shows the value associated with each activity in the largest possible denomination. Is that correct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, or another way of putting it, if the value is too small for a particular denomination (and the result is 0 ETH, for example), it goes to a lower denomination and so on.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ui/app/helpers/transactions.util.js
Outdated
@@ -103,3 +105,13 @@ export async function isSmartContractAddress (address) { | |||
const code = await global.eth.getCode(address) | |||
return code && code !== '0x' | |||
} | |||
|
|||
export function addHex (...args) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe call this sumHexes
so that it is clear it can accept any number of arguments?
} | ||
|
||
default: { | ||
events.push(eventCreator(value, timestamp)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
events.push(eventCreator(value, timestamp))
The eventCreator(value, timestamp)
call needs some default parameter for the eventKey
I wonder if contract deployments should have a different creation message than 'Transaction created with a value of 0 WEI.'? I'm not positive about this, but I think it is worth considering. |
The recipient address in the 'sender-to-recipient' for token transactions should probably be the address of the account to which the tokens were transferred, instead of the contract transaction. |
The previous two comments also apply to Approvals. |
…hin app to Button components
…ivity Log initial ETH value. Add timestamps to Activity Log events
3df31db
to
f1a309e
Compare