sendMax bugfix when returning to previous screen
This commit is contained in:
parent
25965f6268
commit
ee0042b6e7
3 changed files with 12 additions and 6 deletions
|
|
@ -29,6 +29,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory,
|
||||||
vm.finish = finish;
|
vm.finish = finish;
|
||||||
vm.goBack = goBack;
|
vm.goBack = goBack;
|
||||||
vm.loadMore = loadMore;
|
vm.loadMore = loadMore;
|
||||||
|
vm.next = next;
|
||||||
vm.openPopup = openPopup;
|
vm.openPopup = openPopup;
|
||||||
vm.pushDigit = pushDigit;
|
vm.pushDigit = pushDigit;
|
||||||
vm.removeDigit = removeDigit;
|
vm.removeDigit = removeDigit;
|
||||||
|
|
@ -478,7 +479,7 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory,
|
||||||
|
|
||||||
// Currency
|
// Currency
|
||||||
|
|
||||||
var next = 10;
|
var nextCurrencies = 10;
|
||||||
var completeAlternativeList = [];
|
var completeAlternativeList = [];
|
||||||
|
|
||||||
var popularCurrencyList = [
|
var popularCurrencyList = [
|
||||||
|
|
@ -537,12 +538,17 @@ function amountController(configService, $filter, gettextCatalog, $ionicHistory,
|
||||||
|
|
||||||
function loadMore() {
|
function loadMore() {
|
||||||
$timeout(function() {
|
$timeout(function() {
|
||||||
vm.altCurrencyList = completeAlternativeList.slice(0, next);
|
vm.altCurrencyList = completeAlternativeList.slice(0, nextCurrencies);
|
||||||
next += 10;
|
nextCurrencies += 10;
|
||||||
vm.listComplete = vm.altCurrencyList.length >= completeAlternativeList.length;
|
vm.listComplete = vm.altCurrencyList.length >= completeAlternativeList.length;
|
||||||
$scope.$broadcast('scroll.infiniteScrollComplete');
|
$scope.$broadcast('scroll.infiniteScrollComplete');
|
||||||
}, 100);
|
}, 100);
|
||||||
};
|
}
|
||||||
|
|
||||||
|
function next() {
|
||||||
|
useSendMax = false;
|
||||||
|
vm.finish();
|
||||||
|
}
|
||||||
|
|
||||||
function findCurrency(search) {
|
function findCurrency(search) {
|
||||||
if (!search) initCurrencies();
|
if (!search) initCurrencies();
|
||||||
|
|
|
||||||
|
|
@ -223,7 +223,7 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit
|
||||||
// Grab stateParams
|
// Grab stateParams
|
||||||
tx = {
|
tx = {
|
||||||
amount: parseInt(sendFlowData.amount),
|
amount: parseInt(sendFlowData.amount),
|
||||||
sendMax: sendFlowData.sendMax === 'true' ? true : false,
|
sendMax: sendFlowData.sendMax,
|
||||||
fromWalletId: sendFlowData.fromWalletId,
|
fromWalletId: sendFlowData.fromWalletId,
|
||||||
toAddress: sendFlowData.toAddress,
|
toAddress: sendFlowData.toAddress,
|
||||||
paypro: txPayproData,
|
paypro: txPayproData,
|
||||||
|
|
|
||||||
|
|
@ -90,7 +90,7 @@
|
||||||
<button
|
<button
|
||||||
class="button button-full button-primary no-margin"
|
class="button button-full button-primary no-margin"
|
||||||
ng-disabled="!vm.allowSend"
|
ng-disabled="!vm.allowSend"
|
||||||
ng-click="vm.finish()"
|
ng-click="vm.next()"
|
||||||
style="position: absolute; bottom: 0;"
|
style="position: absolute; bottom: 0;"
|
||||||
translate>
|
translate>
|
||||||
Next
|
Next
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue