From 7cb14deaf56d560242fa1f8cbd6331d4b80c21f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gabriel=20Baz=C3=A1n?= Date: Fri, 3 Mar 2017 16:36:31 -0300 Subject: [PATCH] update alternative amount on tx-details view --- src/js/controllers/tx-details.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/js/controllers/tx-details.js b/src/js/controllers/tx-details.js index 05e54d036..9b27d2f0d 100644 --- a/src/js/controllers/tx-details.js +++ b/src/js/controllers/tx-details.js @@ -1,6 +1,6 @@ 'use strict'; -angular.module('copayApp.controllers').controller('txDetailsController', function($log, $ionicHistory, $scope, $timeout, walletService, lodash, gettextCatalog, profileService, configService, externalLinkService, popupService, ongoingProcess) { +angular.module('copayApp.controllers').controller('txDetailsController', function($log, $ionicHistory, $scope, $timeout, walletService, lodash, gettextCatalog, profileService, configService, externalLinkService, popupService, ongoingProcess, txFormatService) { $scope.$on("$ionicView.beforeEnter", function(event, data) { $scope.title = gettextCatalog.getString('Transaction'); @@ -17,7 +17,9 @@ angular.module('copayApp.controllers').controller('txDetailsController', functio $ionicHistory.goBack(); return popupService.showAlert(gettextCatalog.getString('Error'), gettextCatalog.getString('Transaction not found')); } - $scope.btx = tx; + + $scope.btx = txFormatService.processTx(tx); + if ($scope.btx.action != 'invalid') { if ($scope.btx.action == 'sent') $scope.title = gettextCatalog.getString('Sent Funds'); if ($scope.btx.action == 'received') $scope.title = gettextCatalog.getString('Received Funds');