From 3d1b79418a48cdbc2d172f799c34051f3a98ef88 Mon Sep 17 00:00:00 2001 From: Gustavo Maximiliano Cortez Date: Fri, 10 Mar 2017 12:00:57 -0300 Subject: [PATCH] Fix Tx-defailts on iOS. Smoother transition --- src/js/controllers/tx-details.js | 9 +++++---- www/views/tx-details.html | 24 ++++++++++++------------ 2 files changed, 17 insertions(+), 16 deletions(-) diff --git a/src/js/controllers/tx-details.js b/src/js/controllers/tx-details.js index 619bc3781..ea14fb5da 100644 --- a/src/js/controllers/tx-details.js +++ b/src/js/controllers/tx-details.js @@ -17,7 +17,7 @@ angular.module('copayApp.controllers').controller('txDetailsController', functio listeners = [ $rootScope.$on('bwsEvent', function(e, walletId, type, n) { if (type == 'NewBlock' && n && n.data && n.data.network == 'livenet') { - updateTx(); + updateTx({hideLoading: true}); } }) ]; @@ -88,10 +88,11 @@ angular.module('copayApp.controllers').controller('txDetailsController', functio }, 10); } - var updateTx = function() { - ongoingProcess.set('loadingTxInfo', true); + var updateTx = function(opts) { + opts = opts || {}; + if (!opts.hideLoading) ongoingProcess.set('loadingTxInfo', true); walletService.getTx($scope.wallet, txId, function(err, tx) { - ongoingProcess.set('loadingTxInfo', false); + if (!opts.hideLoading) ongoingProcess.set('loadingTxInfo', false); if (err) { $log.warn('Error getting transaction' + err); $ionicHistory.goBack(); diff --git a/www/views/tx-details.html b/www/views/tx-details.html index 2b6eb2e5a..ef8a7c35d 100644 --- a/www/views/tx-details.html +++ b/www/views/tx-details.html @@ -7,8 +7,8 @@ - -
+ +
@@ -26,10 +26,10 @@
{{displayAmount}} {{displayUnit}}
- {{btx.alternativeAmountStr}} - - ... - + {{btx.alternativeAmountStr}} + + ... + {{rate| currency:'':2}} {{alternativeIsoCode}} ({{rateDate | amDateFormat:'MM/DD/YYYY HH:mm a'}}) @@ -80,20 +80,20 @@
Fee - {{btx.feeStr}} - {{feeFiatStr}} + {{btx.feeStr}} + {{feeFiatStr}}
Confirmations - + Unconfirmed - + {{btx.confirmations}} - + {{btx.safeConfirmed}} @@ -125,7 +125,7 @@
-