Merge pull request #34 from colkito/feature/list-and-create-address

Added support for list and create address in a opened wallet
This commit is contained in:
Gustavo Maximiliano Cortez 2014-04-14 17:27:46 -03:00
commit 0941486859
2 changed files with 14 additions and 9 deletions

View file

@ -10,8 +10,15 @@ angular.module('copay.home').controller('HomeController',
$location.path('signin');
}
$scope.addrs = [
{ addrStr: 'n3zUqNR7Bbbc4zJhPVj1vG2Lx66K3Xhzvb'},
{ addrStr: 'my9wnLwwUrwpNfEgSrWY62ymEGf1edKf4J'}
];
$scope.addrs = $rootScope.publicKeyRing.getAddresses();
$scope.selectedAddr = $scope.addrs[0];
$scope.newAddr = function() {
var a = $rootScope.publicKeyRing.generateAddress();
$scope.addrs.push({ addrStr: a.toString('hex') });
};
$scope.selectAddr = function(addr) {
$scope.selectedAddr = addr;
};
});