workaround to link inner childs

This commit is contained in:
Matias Alejo Garcia 2016-10-11 18:30:40 -03:00
commit 6b2cbccecd
No known key found for this signature in database
GPG key ID: 02470DB551277AB3
2 changed files with 15 additions and 2 deletions

View file

@ -143,4 +143,17 @@ angular.module('copayApp.controllers').controller('tabSendController', function(
updateHasFunds();
});
// This could probably be enhanced refactoring the routes abstract states
$scope.createWallet = function() {
$state.go('tabs.home').then(function() {
$state.go('tabs.add.create-personal');
});
};
$scope.buyBitcoin = function() {
$state.go('tabs.home').then(function() {
$state.go('tabs.buyandsell.glidera');
});
};
});

View file

@ -11,8 +11,8 @@
<div class="zero-state-description" ng-show="hasWallets" translate>To get started, buy bitcoin or share your address. You can receive bitcoin from any wallet or service.</div>
<div class="zero-state-description" ng-show="!hasWallets" translate>To get started, you'll need to create a bitcoin wallet and get some bitcoin.</div>
<div class="zero-state-cta">
<button class="button button-standard button-primary" ui-sref="tabs.buyandsell.glidera" ng-show="hasWallets">Buy Bitcoin</button>
<button class="button button-standard button-primary" ui-sref="tabs.add.create-personal" ng-show="!hasWallets">Create bitcoin wallet</button>
<button class="button button-standard button-primary" ng-click="buyBitcoin()" ng-show="hasWallets">Buy Bitcoin</button>
<button class="button button-standard button-primary" ng-click="createWallet()" ng-show="!hasWallets">Create bitcoin wallet</button>
<button class="button button-standard button-secondary" ui-sref="tabs.receive" ng-show="hasWallets">Show bitcoin address</button>
</div>
</div>