mirror of https://github.com/BTCPrivate/copay.git
commit
76c6a96e19
|
@ -276,11 +276,12 @@ angular.module('copayApp.controllers').controller('confirmController', function(
|
||||||
updateAmount();
|
updateAmount();
|
||||||
showSendMaxWarning(sendMaxInfo);
|
showSendMaxWarning(sendMaxInfo);
|
||||||
}
|
}
|
||||||
refresh();
|
|
||||||
|
|
||||||
// txp already generated for this wallet?
|
// txp already generated for this wallet?
|
||||||
if (tx.txp[wallet.id])
|
if (tx.txp[wallet.id]) {
|
||||||
|
refresh();
|
||||||
return cb();
|
return cb();
|
||||||
|
}
|
||||||
|
|
||||||
getTxp(lodash.clone(tx), wallet, opts.dryRun, function(err, txp) {
|
getTxp(lodash.clone(tx), wallet, opts.dryRun, function(err, txp) {
|
||||||
if (err) return cb(err);
|
if (err) return cb(err);
|
||||||
|
@ -297,6 +298,7 @@ angular.module('copayApp.controllers').controller('confirmController', function(
|
||||||
|
|
||||||
tx.txp[wallet.id] = txp;
|
tx.txp[wallet.id] = txp;
|
||||||
$log.debug('Confirm. TX Fully Updated for wallet:' + wallet.id, tx);
|
$log.debug('Confirm. TX Fully Updated for wallet:' + wallet.id, tx);
|
||||||
|
refresh();
|
||||||
|
|
||||||
return cb();
|
return cb();
|
||||||
});
|
});
|
||||||
|
@ -567,16 +569,16 @@ angular.module('copayApp.controllers').controller('confirmController', function(
|
||||||
};
|
};
|
||||||
|
|
||||||
scope.hideModal = function(customFeeLevel) {
|
scope.hideModal = function(customFeeLevel) {
|
||||||
|
scope.chooseFeeLevelModal.hide();
|
||||||
$log.debug('Custom fee level choosen:' + customFeeLevel + ' was:' + tx.feeLevel);
|
$log.debug('Custom fee level choosen:' + customFeeLevel + ' was:' + tx.feeLevel);
|
||||||
if (tx.feeLevel == customFeeLevel)
|
if (tx.feeLevel == customFeeLevel)
|
||||||
scope.chooseFeeLevelModal.hide();
|
return;
|
||||||
|
|
||||||
tx.feeLevel = customFeeLevel;
|
tx.feeLevel = customFeeLevel;
|
||||||
updateTx(tx, wallet, {
|
updateTx(tx, wallet, {
|
||||||
clearCache: true,
|
clearCache: true,
|
||||||
dryRun: true,
|
dryRun: true,
|
||||||
}, function() {
|
}, function() {
|
||||||
scope.chooseFeeLevelModal.hide();
|
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -46,8 +46,10 @@ angular.module('copayApp.controllers').controller('preferencesFeeController', fu
|
||||||
}
|
}
|
||||||
$scope.feeLevels = levels;
|
$scope.feeLevels = levels;
|
||||||
updateCurrentValues();
|
updateCurrentValues();
|
||||||
|
$timeout(function() {
|
||||||
$scope.$apply();
|
$scope.$apply();
|
||||||
});
|
});
|
||||||
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
var updateCurrentValues = function() {
|
var updateCurrentValues = function() {
|
||||||
|
|
|
@ -56,9 +56,7 @@ angular.module('copayApp.services').factory('feeService', function($log, $timeou
|
||||||
root.getFeeLevels = function(cb) {
|
root.getFeeLevels = function(cb) {
|
||||||
|
|
||||||
if (cache.updateTs > Date.now() - CACHE_TIME_TS * 1000) {
|
if (cache.updateTs > Date.now() - CACHE_TIME_TS * 1000) {
|
||||||
$timeout(function() {
|
|
||||||
return cb(null, cache.data, true);
|
return cb(null, cache.data, true);
|
||||||
}, 1);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var walletClient = bwcService.getClient();
|
var walletClient = bwcService.getClient();
|
||||||
|
|
Loading…
Reference in New Issue