add redirs to internal pages
This commit is contained in:
parent
572dff6baf
commit
bdaf40de48
11 changed files with 88 additions and 65 deletions
|
|
@ -2,6 +2,9 @@
|
|||
|
||||
angular.module('copayApp.controllers').controller('AddressesController',
|
||||
function($scope, $rootScope, $timeout, $modal, controllerUtils) {
|
||||
controllerUtils.redirIfNotComplete();
|
||||
|
||||
|
||||
$scope.loading = false;
|
||||
$scope.showAll = false;
|
||||
var w = $rootScope.wallet;
|
||||
|
|
|
|||
|
|
@ -139,9 +139,8 @@ angular.module('copayApp.controllers').controller('JoinController',
|
|||
notification.error('Unknown error');
|
||||
controllerUtils.onErrorDigest();
|
||||
} else {
|
||||
$scope.loading = false;
|
||||
$rootScope.wallet = w;
|
||||
controllerUtils.bindWallet(w, $scope);
|
||||
controllerUtils.installWalletHandlers($scope, w);
|
||||
controllerUtils.setFocusedWallet(w);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,9 +2,11 @@
|
|||
|
||||
angular.module('copayApp.controllers').controller('MoreController',
|
||||
function($scope, $rootScope, $location, $filter, backupService, controllerUtils, notification, rateService) {
|
||||
controllerUtils.redirIfNotComplete();
|
||||
var w = $rootScope.wallet;
|
||||
$scope.isSafari = Object.prototype.toString.call(window.HTMLElement).indexOf('Constructor') > 0;
|
||||
|
||||
|
||||
$scope.unitOpts = [{
|
||||
name: 'Satoshis (100,000,000 satoshis = 1BTC)',
|
||||
shortName: 'SAT',
|
||||
|
|
|
|||
|
|
@ -4,6 +4,8 @@ var preconditions = require('preconditions').singleton();
|
|||
|
||||
angular.module('copayApp.controllers').controller('SendController',
|
||||
function($scope, $rootScope, $window, $timeout, $anchorScroll, $modal, isMobile, notification, controllerUtils, rateService) {
|
||||
controllerUtils.redirIfNotComplete();
|
||||
|
||||
var w = $rootScope.wallet;
|
||||
preconditions.checkState(w);
|
||||
preconditions.checkState(w.settings.unitToSatoshi);
|
||||
|
|
|
|||
|
|
@ -36,11 +36,13 @@ angular.module('copayApp.controllers').controller('SidebarController', function(
|
|||
|
||||
$scope.refresh = function() {
|
||||
var w = $rootScope.wallet;
|
||||
w.sendWalletReady();
|
||||
if ($rootScope.addrInfos.length > 0) {
|
||||
controllerUtils.updateBalance(function() {
|
||||
$rootScope.$digest();
|
||||
});
|
||||
if (w.isReady()) {
|
||||
w.sendWalletReady();
|
||||
if ($rootScope.addrInfos.length > 0) {
|
||||
controllerUtils.updateBalance(function() {
|
||||
$rootScope.$digest();
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -3,6 +3,8 @@ var bitcore = require('bitcore');
|
|||
|
||||
angular.module('copayApp.controllers').controller('TransactionsController',
|
||||
function($scope, $rootScope, $timeout, controllerUtils, notification, rateService) {
|
||||
controllerUtils.redirIfNotComplete();
|
||||
|
||||
|
||||
var w = $rootScope.wallet;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue