diff --git a/src/js/controllers/confirm.js b/src/js/controllers/confirm.js index 6c9934a8b..881da799b 100644 --- a/src/js/controllers/confirm.js +++ b/src/js/controllers/confirm.js @@ -164,7 +164,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( }; function resetValues() { - $scope.displayAmount = $scope.displayUnit = $scope.fee = $scope.feeFiat = $scope.feePercent = $scope.alternativeAmountStr = $scope.insufficientFunds = $scope.noMatchingWallet = null; + $scope.displayAmount = $scope.displayUnit = $scope.fee = $scope.feeFiat = $scope.feeRateStr = $scope.alternativeAmountStr = $scope.insufficientFunds = $scope.noMatchingWallet = null; $scope.showAddress = false; }; @@ -263,7 +263,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( txFormatService.formatAlternativeStr(data.amount, function(v) { $scope.alternativeAmountStr = v; }); - $scope.feePercent = (data.fee * 100 / (data.amount + data.fee)).toFixed(2); + $scope.feeRateStr = (data.fee / (data.amount + data.fee) * 100).toFixed(2) + '%'; $timeout(function() { $scope.$apply(); }); @@ -389,7 +389,7 @@ angular.module('copayApp.controllers').controller('confirmController', function( $scope.feeFiat = v; }); $scope.txp = txp; - $scope.feePercent = (txp.fee * 100 / (txp.amount + txp.fee)).toFixed(2); + $scope.feeRateStr = (txp.fee / (txp.amount + txp.fee) * 100).toFixed(2) + '%'; $timeout(function() { $scope.$apply(); }); diff --git a/src/sass/views/confirm.scss b/src/sass/views/confirm.scss index 6d6425a6f..8adc61672 100644 --- a/src/sass/views/confirm.scss +++ b/src/sass/views/confirm.scss @@ -3,7 +3,7 @@ @extend .deflash-blue; .item-note { float: none; - .fee-percent { + .fee-rate { display: inline-block; } } diff --git a/www/views/confirm.html b/www/views/confirm.html index 8b6ad0df7..b9c65a312 100644 --- a/www/views/confirm.html +++ b/www/views/confirm.html @@ -81,7 +81,7 @@ {{'Fee' | translate}}: {{feeLevel | translate}} {{fee || '...'}} - {{feeFiat || '...'}} - {{feePercent}} % of the transaction + {{feeFiat || '...'}} - {{feeRateStr}} of the transaction diff --git a/www/views/includes/confirm-tx.html b/www/views/includes/confirm-tx.html deleted file mode 100644 index 1743e399c..000000000 --- a/www/views/includes/confirm-tx.html +++ /dev/null @@ -1,39 +0,0 @@ -