Changes as requested by PR.
This commit is contained in:
parent
86be126e95
commit
ccf2dd4586
3 changed files with 7 additions and 6 deletions
|
|
@ -287,9 +287,10 @@ angular.module('copayApp.controllers').controller('confirmController', function(
|
||||||
tx.amountValueStr = tx.amountStr.split(' ')[0];
|
tx.amountValueStr = tx.amountStr.split(' ')[0];
|
||||||
tx.amountUnitStr = tx.amountStr.split(' ')[1];
|
tx.amountUnitStr = tx.amountStr.split(' ')[1];
|
||||||
txFormatService.formatAlternativeStr(wallet.coin, tx.toAmount, function(v) {
|
txFormatService.formatAlternativeStr(wallet.coin, tx.toAmount, function(v) {
|
||||||
|
var parts = v.split(' ');
|
||||||
tx.alternativeAmountStr = v;
|
tx.alternativeAmountStr = v;
|
||||||
tx.alternativeAmountValueStr = tx.alternativeAmountStr.split(' ')[0];
|
tx.alternativeAmountValueStr = parts[0];
|
||||||
tx.alternativeAmountUnitStr = tx.alternativeAmountStr.split(' ')[1];
|
tx.alternativeAmountUnitStr = (parts.length > 0) ? parts[1] : '';
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -428,8 +429,8 @@ angular.module('copayApp.controllers').controller('confirmController', function(
|
||||||
|
|
||||||
|
|
||||||
function showSendMaxWarning(wallet, sendMaxInfo) {
|
function showSendMaxWarning(wallet, sendMaxInfo) {
|
||||||
var feeAlternative,
|
var feeAlternative = '',
|
||||||
msg;
|
msg = '';
|
||||||
|
|
||||||
function verifyExcludedUtxos() {
|
function verifyExcludedUtxos() {
|
||||||
var warningMsg = [];
|
var warningMsg = [];
|
||||||
|
|
|
||||||
|
|
@ -125,7 +125,7 @@ angular.module('copayApp.controllers').controller('tabReceiveController', functi
|
||||||
for (var i = 0; i < data.x.out.length; i++) {
|
for (var i = 0; i < data.x.out.length; i++) {
|
||||||
if (data.x.out[i].addr == watchAddress) {
|
if (data.x.out[i].addr == watchAddress) {
|
||||||
$scope.paymentReceivedAmount = txFormatService.formatAmount(data.x.out[i].value, 'full');
|
$scope.paymentReceivedAmount = txFormatService.formatAmount(data.x.out[i].value, 'full');
|
||||||
$scope.paymentReceivedAlternativeAmount = null; // For when a subsequent payment is received.
|
$scope.paymentReceivedAlternativeAmount = ''; // For when a subsequent payment is received.
|
||||||
txFormatService.formatAlternativeStr($scope.wallet.coin, data.x.out[i].value, function(alternativeStr){
|
txFormatService.formatAlternativeStr($scope.wallet.coin, data.x.out[i].value, function(alternativeStr){
|
||||||
if (alternativeStr) {
|
if (alternativeStr) {
|
||||||
$scope.paymentReceivedAlternativeAmount = alternativeStr;
|
$scope.paymentReceivedAlternativeAmount = alternativeStr;
|
||||||
|
|
|
||||||
|
|
@ -79,7 +79,7 @@ angular.module('copayApp.services').factory('txFormatService', function($filter,
|
||||||
var lessThanPrefix = '';
|
var lessThanPrefix = '';
|
||||||
if (subcent) {
|
if (subcent) {
|
||||||
roundedNum = 0.01;
|
roundedNum = 0.01;
|
||||||
lessThanPrefix = '< '
|
lessThanPrefix = '< ';
|
||||||
}
|
}
|
||||||
var v1 = $filter('formatFiatAmount')(roundedNum);
|
var v1 = $filter('formatFiatAmount')(roundedNum);
|
||||||
if (!v1) return null;
|
if (!v1) return null;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue