Ref chain to coin. Adds create wallet

This commit is contained in:
Gustavo Maximiliano Cortez 2017-08-27 23:50:27 -03:00
commit 2c33f186af
No known key found for this signature in database
GPG key ID: 15EDAD8D9F2EB1AF
37 changed files with 90 additions and 89 deletions

View file

@ -19,7 +19,7 @@ angular.module('copayApp.services').factory('txFormatService', function($filter,
root.formatAmountStr = function(wallet, satoshis) {
if (isNaN(satoshis)) return;
return root.formatAmount(satoshis) + ' ' + wallet.chain;
return root.formatAmount(satoshis) + ' ' + wallet.coin;
};
root.toFiat = function(satoshis, code, cb) {
@ -196,13 +196,13 @@ angular.module('copayApp.services').factory('txFormatService', function($filter,
amountUnitStr = root.formatAmountStr(wallet, amountSat);
// convert sat to BTC or BCH
amount = (amountSat * satToBtc).toFixed(8);
currency = wallet.chain;
currency = (wallet.coin).toUpperCase();
} else {
amountSat = parseInt((amount * unitToSatoshi).toFixed(0));
amountUnitStr = root.formatAmountStr(wallet, amountSat);
// convert unit to BTC or BCH
amount = (amountSat * satToBtc).toFixed(8);
currency = wallet.chain;
currency = (wallet.coin).toUpperCase();
}
return {