Merge pull request #352 from gabrielbazan7/feat/pullToRefresh
pull to refresh
This commit is contained in:
commit
8c52bc3948
4 changed files with 31 additions and 7 deletions
|
|
@ -11,12 +11,13 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
|||
$scope.version = $window.version;
|
||||
$scope.name = $window.appConfig.nameCase;
|
||||
$scope.homeTip = $stateParams.fromOnboarding;
|
||||
$scope.isCordova = platformInfo.isCordova;
|
||||
|
||||
if(!$scope.homeTip){
|
||||
storageService.getHomeTipAccepted(function(error, value){
|
||||
$scope.homeTip = (value == 'false') ? false : true;
|
||||
});
|
||||
}
|
||||
if (!$scope.homeTip) {
|
||||
storageService.getHomeTipAccepted(function(error, value) {
|
||||
$scope.homeTip = (value == 'false') ? false : true;
|
||||
});
|
||||
}
|
||||
|
||||
$scope.openNotificationModal = function(n) {
|
||||
wallet = profileService.getWallet(n.walletId);
|
||||
|
|
@ -170,7 +171,7 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
|||
};
|
||||
|
||||
$scope.hideHomeTip = function() {
|
||||
storageService.setHomeTipAccepted(false, function(error, value){
|
||||
storageService.setHomeTipAccepted(false, function(error, value) {
|
||||
$scope.homeTip = false;
|
||||
});
|
||||
};
|
||||
|
|
@ -201,6 +202,11 @@ angular.module('copayApp.controllers').controller('tabHomeController',
|
|||
});
|
||||
};
|
||||
|
||||
$scope.onRefresh = function() {
|
||||
$scope.$broadcast('scroll.refreshComplete');
|
||||
updateAllWallets();
|
||||
};
|
||||
|
||||
$scope.$on("$ionicView.enter", function(event, data) {
|
||||
$scope.bitpayCard = null;
|
||||
nextStep();
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun
|
|||
$scope.txps = [];
|
||||
$scope.completeTxHistory = [];
|
||||
$scope.openTxpModal = txpModalService.open;
|
||||
$scope.isCordova = platformInfo.isCordova;
|
||||
|
||||
$scope.openExternalLink = function(url, target) {
|
||||
externalLinkService.open(url, target);
|
||||
|
|
@ -159,6 +160,11 @@ angular.module('copayApp.controllers').controller('walletDetailsController', fun
|
|||
}, 100);
|
||||
};
|
||||
|
||||
$scope.onRefresh = function() {
|
||||
$scope.$broadcast('scroll.refreshComplete');
|
||||
$scope.updateAll(true);
|
||||
};
|
||||
|
||||
$scope.updateAll = function(force, cb) {
|
||||
updateStatus(force);
|
||||
updateTxHistory(cb);
|
||||
|
|
|
|||
|
|
@ -4,6 +4,12 @@
|
|||
</ion-nav-bar>
|
||||
|
||||
<ion-content class="padding">
|
||||
<ion-refresher
|
||||
ng-if="isCordova"
|
||||
pulling-icon="ion-ios-refresh"
|
||||
spinner="ios-small"
|
||||
on-refresh="onRefresh()">
|
||||
</ion-refresher>
|
||||
<div class="list card homeTip" ng-if="homeTip">
|
||||
<div class="item item-icon-right item-heading">
|
||||
<a ng-click="hideHomeTip()"><i class="icon ion-ios-close-empty close-home-tip"></i></a>
|
||||
|
|
|
|||
|
|
@ -10,7 +10,13 @@
|
|||
</ion-nav-buttons>
|
||||
</ion-nav-bar>
|
||||
|
||||
<ion-content delegate-handle="my-handle">
|
||||
<ion-content has-bouncing="false">
|
||||
<ion-refresher
|
||||
ng-if="isCordova"
|
||||
pulling-icon="ion-ios-refresh"
|
||||
spinner="ios-small"
|
||||
on-refresh="onRefresh()">
|
||||
</ion-refresher>
|
||||
<div class="oh pr" ng-show="wallet && wallet.isComplete()">
|
||||
<div ng-style="{'background-color':wallet.color}" class="amount">
|
||||
<div ng-if="!notAuthorized && !updatingStatus">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue