Initial change for displaying fiat in "Recent Transactions". Does not yet display loading UI.
This commit is contained in:
parent
9a3e0fdb06
commit
e4d5100753
1 changed files with 13 additions and 2 deletions
|
|
@ -932,8 +932,19 @@ angular.module('copayApp.services')
|
|||
x.txid = x.data ? x.data.txid : null;
|
||||
x.types = [x.type];
|
||||
|
||||
if (x.data && x.data.amount)
|
||||
x.amountStr = txFormatService.formatAmountStr(x.wallet.coin, x.data.amount);
|
||||
if (x.data && x.data.amount) {
|
||||
x.amountStr = null; // Will have loading state in view
|
||||
configService.whenAvailable(function(config) {
|
||||
if (config.wallet.settings.priceDisplay === "fiat") {
|
||||
txFormatService.formatAlternativeStr(x.wallet.coin, x.data.amount, function(formattedString) {
|
||||
x.amountStr = formattedString;
|
||||
// Will I need an apply() after this?
|
||||
});
|
||||
} else {
|
||||
x.amountStr = txFormatService.formatAmountStr(x.wallet.coin, x.data.amount);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
x.action = function() {
|
||||
// TODO?
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue