Display fiat on Payment Received screen, according to preferences.
This commit is contained in:
parent
099db37cb6
commit
a6d2799510
2 changed files with 8 additions and 1 deletions
|
|
@ -125,6 +125,12 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi
|
|||
for (var i = 0; i < data.x.out.length; i++) {
|
||||
if (data.x.out[i].addr == watchAddress) {
|
||||
$scope.paymentReceivedAmount = txFormatService.formatAmount(data.x.out[i].value, 'full');
|
||||
$scope.paymentReceivedAlternativeAmount = null; // For when a subsequent payment is received.
|
||||
txFormatService.formatAlternativeStr($scope.wallet.coin, data.x.out[i].value, function(alternativeStr){
|
||||
if (alternativeStr) {
|
||||
$scope.paymentReceivedAlternativeAmount = alternativeStr;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
$scope.paymentReceivedCoin = $scope.wallet.coin;
|
||||
|
|
|
|||
|
|
@ -61,7 +61,8 @@
|
|||
</svg>
|
||||
<p class="success animated fadeIn">
|
||||
<br/>Payment Received!
|
||||
<span class="payment-received-amount">{{ paymentReceivedAmount }} <span class="payment-received-currency">{{ paymentReceivedCoin }}</span></span>
|
||||
<span ng-if="!(displayBalanceAsFiat && paymentReceivedAlternativeAmount)" class="payment-received-amount">{{ paymentReceivedAmount }} <span class="payment-received-currency">{{ paymentReceivedCoin }}</span></span>
|
||||
<span ng-if="displayBalanceAsFiat && paymentReceivedAlternativeAmount" class="payment-received-amount">{{ paymentReceivedAlternativeAmount }}</span></span>
|
||||
Return To Address<br/>
|
||||
</p>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue