mirror of https://github.com/BTCPrivate/copay.git
m-of-n integration complete
This commit is contained in:
parent
b504074009
commit
9df76b90fd
|
@ -102,6 +102,7 @@
|
|||
Connecting to wallet...
|
||||
</div>
|
||||
<div ng-show="!loading">
|
||||
<h2>Create new multisig wallet</h2>
|
||||
<div class="row">
|
||||
<div class="large-6 columns">
|
||||
<h3>Select total number of copayers</h3>
|
||||
|
@ -120,7 +121,9 @@
|
|||
</div>
|
||||
<div class="large-3 columns">
|
||||
<button class="button primary expand round" type="button"
|
||||
ng-click="create(totalCopayers, requiredCopayers)">Create</button>
|
||||
ng-click="create(totalCopayers, requiredCopayers)">
|
||||
Create {{requiredCopayers}}-of-{{totalCopayers}} wallet
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -31,12 +31,17 @@ angular.module('copay.setup').controller('SetupController',
|
|||
requiredCopayers: requiredCopayers,
|
||||
totalCopayers: totalCopayers
|
||||
};
|
||||
var w = walletFactory.create();
|
||||
w.on('open', function(){
|
||||
var w = walletFactory.create(opts);
|
||||
w.on('created', function(){
|
||||
$location.path('peer');
|
||||
$rootScope.wallet = w;
|
||||
$rootScope.$digest();
|
||||
});
|
||||
w.on('openError', function(){
|
||||
$scope.loading = false;
|
||||
$rootScope.flashMessage = {type:'error', message: 'Wallet not found'};
|
||||
$location.path('signin');
|
||||
});
|
||||
w.netStart();
|
||||
};
|
||||
|
||||
|
|
|
@ -27,12 +27,7 @@ angular.module('copay.signin').controller('SigninController',
|
|||
};
|
||||
|
||||
$scope.create = function() {
|
||||
console.log('[signin.js.42:create:]'); //TODO
|
||||
$scope.loading = true;
|
||||
|
||||
var w = walletFactory.create();
|
||||
_setupUxHandlers(w);
|
||||
w.netStart();
|
||||
$location.path('setup');
|
||||
};
|
||||
|
||||
$scope.open = function(walletId) {
|
||||
|
|
|
@ -22,6 +22,8 @@ function Wallet(opts) {
|
|||
self[k] = opts[k];
|
||||
});
|
||||
|
||||
console.log('creating '+opts.requiredCopayers+' of '+opts.totalCopayers+' wallet');
|
||||
|
||||
this.id = opts.id || Wallet.getRandomId();
|
||||
this.publicKeyRing.walletId = this.id;
|
||||
this.txProposals.walletId = this.id;
|
||||
|
|
Loading…
Reference in New Issue