Merge pull request #3429 from cmgustavo/updates/angular-bwc-117
Fixes join wallet. Updates angular-bwc
This commit is contained in:
commit
6087541a6d
2 changed files with 4 additions and 6 deletions
|
|
@ -8,7 +8,7 @@
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"angular": "1.4.6",
|
"angular": "1.4.6",
|
||||||
"angular-bitcore-wallet-client": "1.1.6",
|
"angular-bitcore-wallet-client": "1.1.7",
|
||||||
"angular-foundation": "0.7.0",
|
"angular-foundation": "0.7.0",
|
||||||
"angular-gettext": "2.1.0",
|
"angular-gettext": "2.1.0",
|
||||||
"angular-moment": "0.10.1",
|
"angular-moment": "0.10.1",
|
||||||
|
|
|
||||||
|
|
@ -11,15 +11,13 @@ angular.module('copayApp.services')
|
||||||
root.focusedClient = null;
|
root.focusedClient = null;
|
||||||
root.walletClients = {};
|
root.walletClients = {};
|
||||||
|
|
||||||
root.getUtils = function() {
|
root.Utils = bwcService.getUtils();
|
||||||
return bwcService.getUtils();
|
|
||||||
};
|
|
||||||
root.formatAmount = function(amount) {
|
root.formatAmount = function(amount) {
|
||||||
var config = configService.getSync().wallet.settings;
|
var config = configService.getSync().wallet.settings;
|
||||||
if (config.unitCode == 'sat') return amount;
|
if (config.unitCode == 'sat') return amount;
|
||||||
|
|
||||||
//TODO : now only works for english, specify opts to change thousand separator and decimal separator
|
//TODO : now only works for english, specify opts to change thousand separator and decimal separator
|
||||||
return this.getUtils().formatAmount(amount, config.unitCode);
|
return this.Utils.formatAmount(amount, config.unitCode);
|
||||||
};
|
};
|
||||||
|
|
||||||
root._setFocus = function(walletId, cb) {
|
root._setFocus = function(walletId, cb) {
|
||||||
|
|
@ -274,7 +272,7 @@ angular.module('copayApp.services')
|
||||||
$log.debug('Joining Wallet:', opts);
|
$log.debug('Joining Wallet:', opts);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
var walletData = this.getUtils().fromSecret(opts.secret);
|
var walletData = bwcService.parseSecret(opts.secret);
|
||||||
|
|
||||||
// check if exist
|
// check if exist
|
||||||
if (lodash.find(root.profile.credentials, {
|
if (lodash.find(root.profile.credentials, {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue