Merge pull request #4930 from gabrielbazan7/fix/nextSteps
fix next steps
This commit is contained in:
commit
070ce0470a
1 changed files with 23 additions and 18 deletions
|
|
@ -197,13 +197,13 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
var nextStep = function() {
|
var nextStep = function(cb) {
|
||||||
lodash.each(['AmazonGiftCards', 'BitpayCard', 'BuyAndSell'], function(service) {
|
var i = 0;
|
||||||
|
var services = ['AmazonGiftCards', 'BitpayCard', 'BuyAndSell'];
|
||||||
|
lodash.each(services, function(service) {
|
||||||
storageService.getNextStep(service, function(err, value) {
|
storageService.getNextStep(service, function(err, value) {
|
||||||
$scope.externalServices[service] = value ? true : false;
|
$scope.externalServices[service] = value ? true : false;
|
||||||
$timeout(function() {
|
if (++i == services.length) return cb();
|
||||||
$ionicScrollDelegate.resize();
|
|
||||||
}, 10);
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
@ -243,7 +243,6 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
||||||
};
|
};
|
||||||
|
|
||||||
$scope.$on("$ionicView.enter", function(event, data) {
|
$scope.$on("$ionicView.enter", function(event, data) {
|
||||||
nextStep();
|
|
||||||
updateAllWallets();
|
updateAllWallets();
|
||||||
|
|
||||||
addressbookService.list(function(err, ab) {
|
addressbookService.list(function(err, ab) {
|
||||||
|
|
@ -264,6 +263,7 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
||||||
];
|
];
|
||||||
|
|
||||||
configService.whenAvailable(function() {
|
configService.whenAvailable(function() {
|
||||||
|
nextStep(function() {
|
||||||
var config = configService.getSync();
|
var config = configService.getSync();
|
||||||
var isWindowsPhoneApp = platformInfo.isWP && platformInfo.isCordova;
|
var isWindowsPhoneApp = platformInfo.isWP && platformInfo.isCordova;
|
||||||
|
|
||||||
|
|
@ -280,6 +280,11 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
||||||
$scope.recentTransactionsEnabled = config.recentTransactions.enabled;
|
$scope.recentTransactionsEnabled = config.recentTransactions.enabled;
|
||||||
|
|
||||||
if ($scope.bitpayCardEnabled) bitpayCardCache();
|
if ($scope.bitpayCardEnabled) bitpayCardCache();
|
||||||
|
$timeout(function() {
|
||||||
|
$ionicScrollDelegate.resize();
|
||||||
|
$scope.$apply();
|
||||||
|
}, 10);
|
||||||
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue