Skip to content
This repository has been archived by the owner on Nov 21, 2019. It is now read-only.

Commit

Permalink
changed to pending and fixed donate button
Browse files Browse the repository at this point in the history
  • Loading branch information
kvhnuke committed May 14, 2017
1 parent bb7958c commit 430a3e0
Show file tree
Hide file tree
Showing 4 changed files with 111,161 additions and 96,862 deletions.
3 changes: 1 addition & 2 deletions app/scripts/controllers/sendTxCtrl.js
Original file line number Diff line number Diff line change
Expand Up @@ -167,8 +167,7 @@ var sendTxCtrl = function($scope, $sce, walletService) {
return new BigNumber($scope.tx.value).lt(new BigNumber($scope.wallet.balance));
}
$scope.onDonateClick = function() {
//$scope.addressDrtv.ensAddressField = globalFuncs.donateAddress;
$scope.tx.to = globalFuncs.donateAddress;
$scope.addressDrtv.ensAddressField = globalFuncs.donateAddress;
$scope.tx.value = "1";
$scope.tx.donate = true;
}
Expand Down
8 changes: 4 additions & 4 deletions app/scripts/nodeHelpers/customNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ customNode.prototype.getChainId = function(callback) {
customNode.prototype.getBalance = function(addr, callback) {
this.post({
method: 'eth_getBalance',
params: [addr, 'latest']
params: [addr, 'pending']
}, function(data) {
if (data.error) callback({ error: true, msg: data.error.message, data: '' });
else callback({ error: false, msg: '', data: { address: addr, balance: new BigNumber(data.result).toString() } });
Expand All @@ -41,9 +41,9 @@ customNode.prototype.getTransactionData = function(addr, callback) {
var response = { error: false, msg: '', data: { address: addr, balance: '', gasprice: '', nonce: '' } };
var parentObj = this;
var reqObj = [
{ "id": globalFuncs.getRandomBytes(16).toString('hex'), "jsonrpc": "2.0", "method": "eth_getBalance", "params": [addr, 'latest'] },
{ "id": globalFuncs.getRandomBytes(16).toString('hex'), "jsonrpc": "2.0", "method": "eth_getBalance", "params": [addr, 'pending'] },
{ "id": globalFuncs.getRandomBytes(16).toString('hex'), "jsonrpc": "2.0", "method": "eth_gasPrice", "params": [] },
{ "id": globalFuncs.getRandomBytes(16).toString('hex'), "jsonrpc": "2.0", "method": "eth_getTransactionCount", "params": [addr, 'latest'] }
{ "id": globalFuncs.getRandomBytes(16).toString('hex'), "jsonrpc": "2.0", "method": "eth_getTransactionCount", "params": [addr, 'pending'] }
];
this.rawPost(reqObj, function(data) {
for (var i in data) {
Expand Down Expand Up @@ -80,7 +80,7 @@ customNode.prototype.getEstimatedGas = function(txobj, callback) {
customNode.prototype.getEthCall = function(txobj, callback) {
this.post({
method: 'eth_call',
params: [{ to: txobj.to, data: txobj.data },'latest']
params: [{ to: txobj.to, data: txobj.data },'pending']
}, function(data) {
if (data.error) callback({ error: true, msg: data.error.message, data: '' });
else callback({ error: false, msg: '', data: data.result });
Expand Down
Loading

0 comments on commit 430a3e0

Please sign in to comment.