ionic modals in coinbase and glidera and delete confirmation
This commit is contained in:
parent
1524d26f10
commit
d2bdca00f4
28 changed files with 566 additions and 717 deletions
30
src/js/controllers/modals/wallets.js
Normal file
30
src/js/controllers/modals/wallets.js
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
'use strict';
|
||||
|
||||
angular.module('copayApp.controllers').controller('walletsController', function($scope, bwsError, profileService) {
|
||||
|
||||
var self = $scope.self;
|
||||
|
||||
$scope.selectWallet = function(walletId, walletName) {
|
||||
if (!profileService.getClient(walletId).isComplete()) {
|
||||
self.error = bwsError.msg({
|
||||
'code': 'WALLET_NOT_COMPLETE'
|
||||
}, 'Could not choose the wallet');
|
||||
self.error = {
|
||||
errors: [{
|
||||
message: 'The Wallet could not be selected'
|
||||
}]
|
||||
};
|
||||
$scope.cancel();
|
||||
return;
|
||||
}
|
||||
self.selectedWalletId = walletId;
|
||||
self.selectedWalletName = walletName;
|
||||
self.fc = profileService.getClient(self.selectedWalletId);
|
||||
$scope.cancel();
|
||||
};
|
||||
|
||||
$scope.cancel = function() {
|
||||
$scope.walletsModal.hide();
|
||||
};
|
||||
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue