rm index from tab-home
This commit is contained in:
parent
2c70caa7a8
commit
6cc3487818
3 changed files with 12 additions and 4 deletions
|
|
@ -3,7 +3,7 @@
|
|||
<ion-nav-bar class="bar-stable">
|
||||
<ion-nav-title>Home</ion-nav-title>
|
||||
</ion-nav-bar>
|
||||
<ion-content class="padding home" ng-controller="tabHomeController" cache-view="false">
|
||||
<ion-content class="padding home" ng-controller="tabHomeController" cache-view="false" ng-init="init()">
|
||||
|
||||
<div ng-if="txps[0]">
|
||||
<h3 class="title m0" translate>Payment Proposals</h3>
|
||||
|
|
@ -85,7 +85,7 @@
|
|||
<i class="icon ion-card"></i>
|
||||
BitPay Card
|
||||
</li>
|
||||
<li ng-show="!index.isWindowsPhoneApp && (index.glideraEnabled || index.coinbaseEnabled)" menu-toggle href ui-sref="buyandsell" class="item item-icon-left">
|
||||
<li ng-show="buyAndSellEnabled" menu-toggle href ui-sref="buyandsell" class="item item-icon-left">
|
||||
<i class="icon ion-cash"></i>
|
||||
Buy and Sell
|
||||
</li>
|
||||
|
|
|
|||
|
|
@ -1,9 +1,10 @@
|
|||
'use strict';
|
||||
|
||||
angular.module('copayApp.controllers').controller('tabHomeController',
|
||||
function($rootScope, $timeout, $scope, $state, lodash, profileService, walletService, configService, txFormatService, $ionicModal, $log) {
|
||||
function($rootScope, $timeout, $scope, $state, lodash, profileService, walletService, configService, txFormatService, $ionicModal, $log, platformInfo) {
|
||||
var self = this;
|
||||
|
||||
self.glideraEnabled = configService.getSync().glidera.enabled;
|
||||
|
||||
// wallet list change
|
||||
$rootScope.$on('Local/WalletListUpdated', function(event) {
|
||||
|
|
@ -135,5 +136,12 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
|||
});
|
||||
};
|
||||
|
||||
// $state.transitionTo('confirm', {toAmount:555500, toAddress: 'mvfAwUJohJWibGzBZgAUGsDarsr4Z4NovU', toName: 'bla bla'});
|
||||
$scope.init = function() {
|
||||
var config = configService.getSync();
|
||||
var isWindowsPhoneApp = platformInfo.isWP && isCordova;
|
||||
var glideraEnabled = config.glidera.enabled;
|
||||
var coinbaseEnabled = config.coinbase.enabled;
|
||||
$scope.buyAndSellEnabled = !isWindowsPhoneApp && (glideraEnabled || coinbaseEnabled);
|
||||
}
|
||||
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue