feat: add transferFrom
and approve
to input address for ERC20 contract
#271
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What
This PR adds the ability to perform
transferFrom
function calls, and do the complete flow (from approve to transfer from) dynamically to the desired addresses.Notice the ERC20 token already had
transferFrom
andapprove
support, so there is no need to change anything on the contract level.How
approve
input is the one that was previously hardcoded. The reason for that is because this way, we don't need to change any existing e2e tests relying on approving to that address. You can change the address just by entering a different inputtransferFrom
addresses can be changed dynamically with an input elementapprove
amount is still hardcoded, as this can be changed from the UI if desiredtransferFrom
amount is hardcoded, as there is no relevance on which amount we are transferringScreenshots
transfer-from-flow.mp4
Manual Testing Steps