add support for funding

This commit is contained in:
Josh Harvey 2017-06-17 01:38:51 +03:00
parent 8440fa3b1d
commit bf0dc3f7f3
15 changed files with 731 additions and 356 deletions

View file

@ -68,6 +68,16 @@ function newAddress (settings, info) {
.then(r => r.wallet.newAddress(r.account, info))
}
function newFunding (settings, cryptoCode, address) {
return fetchWallet(settings, cryptoCode)
.then(r => {
const wallet = r.wallet
const account = r.account
return wallet.newFunding(account, cryptoCode)
})
}
function getWalletStatus (settings, tx) {
return fetchWallet(settings, tx.cryptoCode)
.then(r => r.wallet.getStatus(r.account, tx.toAddress, tx.cryptoAtoms, tx.cryptoCode))
@ -135,5 +145,6 @@ module.exports = {
newAddress,
getStatus,
sweep,
isHd
isHd,
newFunding
}