Merge.
This commit is contained in:
commit
9273fb6407
3 changed files with 18 additions and 7 deletions
|
|
@ -105,6 +105,10 @@ function reviewController(addressbookService, bitcoinCashJsService, bitcore, bit
|
|||
}
|
||||
|
||||
vm.approve = function() {
|
||||
if (vm.thirdParty.id === 'shapeshift') {
|
||||
shapeshiftService.shiftIt();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!tx || !vm.originWallet) return;
|
||||
|
||||
|
|
|
|||
|
|
@ -1,26 +1,32 @@
|
|||
'use strict';
|
||||
angular.module('copayApp.services').factory('shapeshiftService', function($http, $log, lodash, moment, ongoingProcess, shapeshiftApiService, storageService, configService, platformInfo, servicesService) {
|
||||
angular.module('copayApp.services').factory('shapeshiftService', function($http, $interval, $log, lodash, moment, ongoingProcess, shapeshiftApiService, storageService, configService, incomingData, platformInfo, servicesService) {
|
||||
var root = {};
|
||||
root.ShiftState = 'Shift';
|
||||
root.withdrawalAddress = ''
|
||||
root.returnAddress = ''
|
||||
root.amount = '';
|
||||
root.marketData = {}
|
||||
this.withdrawalAddress = function(address) {
|
||||
root.withdrawalAddress = function(address) {
|
||||
root.withdrawalAddress = address;
|
||||
};
|
||||
this.returnAddress = function(address) {
|
||||
root.returnAddress = function(address) {
|
||||
root.returnAddress = address;
|
||||
};
|
||||
this.amount = function(amount) {
|
||||
root.amount = function(amount) {
|
||||
root.amount = amount;
|
||||
};
|
||||
this.fromWalletId = function(id) {
|
||||
root.fromWalletId = function(id) {
|
||||
root.fromWalletId = id;
|
||||
};
|
||||
this.toWalletId = function(id) {
|
||||
root.toWalletId = function(id) {
|
||||
root.toWalletId = id;
|
||||
};
|
||||
root.coinIn = function(coinIn) {
|
||||
root.coinIn = coinIn.toUpperCase();
|
||||
};
|
||||
root.coinOut = function(coinOut) {
|
||||
root.coinOut = coinOut.toUpperCase();
|
||||
};
|
||||
|
||||
root.getMarketDataIn = function(coin) {
|
||||
if(coin === root.coinOut) return root.getMarketData(root.coinOut, root.coinIn);
|
||||
|
|
@ -104,6 +110,7 @@ angular.module('copayApp.services').factory('shapeshiftService', function($http,
|
|||
|
||||
var shapeshiftData = {
|
||||
fromWalletId: root.fromWalletId,
|
||||
toWalletId: root.toWalletId,
|
||||
minAmount: root.marketData.minimum,
|
||||
maxAmount: root.marketData.maxLimit,
|
||||
orderId: root.depositInfo.orderId
|
||||
|
|
|
|||
|
|
@ -18,6 +18,6 @@
|
|||
}
|
||||
}
|
||||
.header.shapeshift {
|
||||
background: url(../img/shapeshiftbg.jpg) center center no-repeat #28394d;
|
||||
background: url(../img/shapeshiftbg.jpg) center center repeat #28394d;
|
||||
opacity: 0.99;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue