fix formatAlternativeStr method in confirm.ts

This commit is contained in:
JDonadio 2017-11-09 16:45:37 -03:00
parent 7fb85cb468
commit 99e4d11ace
No known key found for this signature in database
GPG Key ID: EC1F4E04B2BFA730
1 changed files with 2 additions and 6 deletions

View File

@ -331,9 +331,7 @@ export class ConfirmPage {
tx.amountStr = this.txFormatProvider.formatAmountStr(wallet.coin, tx.amount);
tx.amountValueStr = tx.amountStr.split(' ')[0];
tx.amountUnitStr = tx.amountStr.split(' ')[1];
this.txFormatProvider.formatAlternativeStr(wallet.coin, tx.amount).then((v: string) => {
tx.alternativeAmountStr = v;
});
tx.alternativeAmountStr = this.txFormatProvider.formatAlternativeStr(wallet.coin, tx.amount);
}
updateAmount();
@ -382,9 +380,7 @@ export class ConfirmPage {
this.getTxp(_.clone(tx), wallet, opts.dryRun).then((txp: any) => {
this.onGoingProcessProvider.set('calculatingFee', false);
txp.feeStr = this.txFormatProvider.formatAmountStr(wallet.coin, txp.fee);
this.txFormatProvider.formatAlternativeStr(wallet.coin, txp.fee).then((value: string) => {
txp.alternativeFeeStr = value;
});
txp.alternativeFeeStr = this.txFormatProvider.formatAlternativeStr(wallet.coin, txp.fee);
let per = (txp.fee / (txp.amount + txp.fee) * 100);
txp.feeRatePerStr = per.toFixed(2) + '%';