Merge branch 'ref/design' of https://github.com/bitpay/bitpay-wallet into feature/onboarding_screenshot_warning_model

This commit is contained in:
Jamal Jackson 2016-09-15 09:37:36 -04:00
commit be58b7983d
38 changed files with 393 additions and 75 deletions

View file

@ -212,4 +212,14 @@ angular.module('copayApp.controllers').controller('backupController',
$scope.selectComplete = false;
};
$scope.backupGoBack = function() {
if ($stateParams.fromOnboarding) $state.go('onboarding.backupWarning', {
walletId: $stateParams.walletId,
fromOnboarding: true
});
else $state.go('tabs.preferences.main', {
walletId: $stateParams.walletId
});
};
});

View file

@ -27,6 +27,14 @@ angular.module('copayApp.controllers').controller('buyAmazonController',
});
};
this.confirm = function() {
var title = gettextCatalog.getString('Confirm Amazon.com Gift Card purchase for ${{amount}} USD', {amount: $scope.fiat});
var ok = gettextCatalog.getString('Buy');
popupService.showConfirm(title, null, ok, null, function(res) {
if (res) self.createTx();
});
};
this.createTx = function() {
self.errorInfo = null;

View file

@ -1,8 +1,9 @@
'use strict';
angular.module('copayApp.controllers').controller('disclaimerController', function($scope, $timeout, $state, $log, $ionicModal, profileService) {
angular.module('copayApp.controllers').controller('disclaimerController', function($scope, $timeout, $state, $log, $ionicModal, profileService, uxLanguage, externalLinkService) {
$scope.init = function() {
$scope.lang = uxLanguage.currentLanguage;
$scope.terms = {};
$scope.accept1 = $scope.accept2 = $scope.accept3 = false;
$timeout(function() {
@ -19,6 +20,10 @@ angular.module('copayApp.controllers').controller('disclaimerController', functi
});
};
$scope.openExternalLink = function(url, target) {
externalLinkService.open(url, target);
};
$scope.openTermsModal = function() {
$ionicModal.fromTemplateUrl('views/modals/terms.html', {
scope: $scope

View file

@ -13,10 +13,10 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi
if (!$scope.isCordova) $scope.checkTips();
}
$scope.checkTips = function() {
$scope.checkTips = function(force) {
storageService.getReceiveTipsAccepted(function(err, accepted) {
if (err) $log.warn(err);
if (accepted) return;
if (accepted && !force) return;
$timeout(function() {
$ionicModal.fromTemplateUrl('views/modals/receive-tips.html', {
@ -25,7 +25,7 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi
$scope.receiveTipsModal = modal;
$scope.receiveTipsModal.show();
});
}, 1000);
}, force ? 1 : 1000);
});
};