diff --git a/js/controllers/send.js b/js/controllers/send.js index eac2f8e2b..923313a1a 100644 --- a/js/controllers/send.js +++ b/js/controllers/send.js @@ -33,8 +33,8 @@ angular.module('copayApp.controllers').controller('SendController', $scope.setAlternativeAmount = function(w, tx, cb) { rateService.whenAvailable(function() { _.each(tx.outs, function(out) { - var valueSat = out.value * w.settings.unitToSatoshi; - out.alternativeAmount = rateService.toFiat(valueSat, $scope.alternativeIsoCode); + var valueSat = out.valueSat * w.settings.unitToSatoshi; + out.alternativeAmount = $filter('noFractionNumber')(rateService.toFiat(valueSat, $scope.alternativeIsoCode)); out.alternativeIsoCode = $scope.alternativeIsoCode; }); if (cb) return cb(tx); @@ -56,6 +56,7 @@ angular.module('copayApp.controllers').controller('SendController', } if (tx.outs) { _.each(tx.outs, function(out) { + out.valueSat = out.value; out.value = $filter('noFractionNumber')(out.value); }); } diff --git a/views/history.html b/views/history.html index 038294efc..d438af1b9 100644 --- a/views/history.html +++ b/views/history.html @@ -50,7 +50,7 @@ 'green' : btx.action == 'received', 'red': btx.action == 'sent', 'gray': btx.action == 'moved'}" ng-show="btx.alternativeAmount != null"> - {{btx.alternativeAmount| noFractionNumber}} {{$root.wallet.settings.alternativeIsoCode}} + {{btx.alternativeAmount}} {{$root.wallet.settings.alternativeIsoCode}}