diff --git a/app/partials/sfox/checkout.pug b/app/partials/sfox/checkout.pug
index 98c4380ff1..5489c9d258 100644
--- a/app/partials/sfox/checkout.pug
+++ b/app/partials/sfox/checkout.pug
@@ -40,6 +40,10 @@ bc-tabs(tab="tabs.selectedTab" tab-options="tabs.options" on-select="tabs.select
span
i.pointer.ti-close.f-14.mid-grey(ng-click="checkout.dismissBuyIntro()")
p.f-12.mt-10(translate="SFOX.buy.INTRODUCING_BODY")
+ .width-50.pl-30.prn.pv-10-mobile.no-margin-mobile(ng-if="pendingBuyTrades().length")
+ span You have {{ pendingBuyTrades().length }} pending buy {{ pendingBuyTrades().length === 1 ? 'transaction' : 'transactions' }} for a total of {{ pendingBuyTradesTotal() }} BTC. You can see more details in your
+ |
+ a(ng-click="tabs.select('ORDER_HISTORY')") Order History.
.flex-row.pbvl(ng-show="tabs.selectedTab === 'SELL_BITCOIN' && checkout.onStep('create')")
.border-desktop.ph-30.pv-30.width-50.no-padding-mobile(ng-controller="SfoxSellCheckoutController")
exchange-checkout(
diff --git a/app/templates/exchange/confirm.pug b/app/templates/exchange/confirm.pug
index a097567f5d..20eb3705de 100644
--- a/app/templates/exchange/confirm.pug
+++ b/app/templates/exchange/confirm.pug
@@ -29,7 +29,8 @@ form.bc-form.pv-20(
.pts
input(type="checkbox" id="terms" name="terms" ng-model="terms" required)
label.mbn.f-13.em-300(ng-if="!$ctrl.tradeAccount" for="terms" translate=".ACCEPT_TERMS")
- label.mt-15.mb-20.ml-5.f-11.em-300(ng-if="$ctrl.tradeAccount" for="terms" translate=".ACCEPT_TERMS_EXTENDED" translate-values="{account: $ctrl.tradeAccount.accountNumber}")
+ label.mt-15.mb-20.ml-5.f-11.em-300(ng-if="$ctrl.tradeAccount && type === '.buy'" for="terms" translate=".ACCEPT_TERMS_EXTENDED" translate-values="{account: $ctrl.tradeAccount.accountNumber}")
+ label.mt-15.mb-20.ml-5.f-11.em-300(ng-if="$ctrl.tradeAccount && type === '.sell'" for="terms" translate=".ACCEPT_TERMS_EXTENDED" translate-values="{account: $ctrl.tradeAccount.accountNumber}")
.flex-row.flex-end
button.button-muted(type="button" translate="CANCEL" ng-click="$ctrl.onCancel()")
button.button-primary.ml-20(
diff --git a/assets/js/controllers/sfox/sfoxCheckout.controller.js b/assets/js/controllers/sfox/sfoxCheckout.controller.js
index 033e32a0d4..31dc64aad8 100644
--- a/assets/js/controllers/sfox/sfoxCheckout.controller.js
+++ b/assets/js/controllers/sfox/sfoxCheckout.controller.js
@@ -9,6 +9,8 @@ function SfoxCheckoutController ($scope, $timeout, $stateParams, $q, Wallet, MyW
let buyLinks = env.partners.sfox.buySurveyLinks;
$scope.showBuy = () => MyWallet.wallet.accountInfo.invited.sfoxBuy;
+ $scope.pendingBuyTrades = () => $scope.pendingTrades().filter((t) => t.isBuy);
+ $scope.pendingBuyTradesTotal = () => $scope.pendingBuyTrades().map((t) => t.receiveAmount).reduce((acc, amt) => acc + amt);
this.handleCancel = (skipConfirm, type, step) => {
if (skipConfirm) $scope.checkout.goTo('create');
diff --git a/assets/js/controllers/wallet.controller.js b/assets/js/controllers/wallet.controller.js
index e4a3610607..d18e19f791 100644
--- a/assets/js/controllers/wallet.controller.js
+++ b/assets/js/controllers/wallet.controller.js
@@ -104,38 +104,12 @@ function WalletCtrl ($scope, $rootScope, Wallet, $uibModal, $timeout, Alerts, $i
}
};
- let ensureMetadataReady = () => {
- if (!wallet.isMetadataReady) {
- Wallet.askForSecondPasswordIfNeeded()
- .then(pw => Wallet.my.wallet.cacheMetadataKey(pw))
- .then(() => {
- Alerts.displaySuccess('NEEDS_REFRESH');
- $rootScope.needsRefresh = true;
- });
- event.preventDefault();
- return true;
- } else if ($rootScope.needsRefresh) {
- Alerts.displayError('NEEDS_REFRESH');
- event.preventDefault();
- return true;
- } else if (wallet.external === null) {
- // Metadata service connection failed
- Alerts.displayError('POOR_CONNECTION');
- event.preventDefault();
- return true;
- }
- };
-
if (Wallet.status.isLoggedIn && $scope.isPublicState(toState.name)) {
event.preventDefault();
} else {
switch (toState.name) {
case 'wallet.common.buy-sell': return (
- featureDisabledWhen($scope.buySellDisabled, $scope.buySellDisabledReason) ||
- ensureMetadataReady() ||
- featureDisabledWhen(wallet.external.coinify.user && coinify.disabled, coinify.disabledReason) ||
- featureDisabledWhen(wallet.external.unocoin.user && unocoin.disabled, unocoin.disabledReason) ||
- featureDisabledWhen(wallet.external.sfox.user && sfox.disabled, sfox.disabledReason)
+ featureDisabledWhen($scope.buySellDisabled, $scope.buySellDisabledReason)
);
case 'wallet.common.buy-sell.coinify': return (
featureDisabledWhen(coinify.disabled, coinify.disabledReason)
diff --git a/assets/js/services/wallet.service.js b/assets/js/services/wallet.service.js
index 6ce47b492e..957cf91374 100644
--- a/assets/js/services/wallet.service.js
+++ b/assets/js/services/wallet.service.js
@@ -803,9 +803,9 @@ function Wallet ($http, $window, $timeout, $location, $injector, Alerts, MyWalle
case void 0:
if (wallet.my.wallet.isUpgradedToHD) {
if (wallet.my.wallet.balanceActiveLegacy == null || wallet.my.wallet.hdwallet.balanceActiveAccounts == null) return null;
- return wallet.my.wallet.hdwallet.balanceActiveAccounts + wallet.my.wallet.balanceActiveLegacy;
+ return wallet.my.wallet.hdwallet.balanceActiveAccounts + wallet.my.wallet.balanceSpendableActiveLegacy;
} else {
- return wallet.my.wallet.balanceActiveLegacy;
+ return wallet.my.wallet.balanceSpendableActiveLegacy;
}
case 'imported':
return wallet.my.wallet.balanceActiveLegacy;
diff --git a/locales/en-human.json b/locales/en-human.json
index cf3f20fb70..e604373ea5 100644
--- a/locales/en-human.json
+++ b/locales/en-human.json
@@ -1896,7 +1896,7 @@
"confirm": {
"HEADER": "Confirm Sell Order",
"BODY": "Please review your trade details below. Click 'Confirm' to initiate.",
- "ACCEPT_TERMS": "I agree to SFOX's terms and conditions."
+ "ACCEPT_TERMS_EXTENDED": "I authorize SFOX, Inc. to credit my linked bank account ending in {{::account}} via ACH and acknowledge that all transactions to/from my bank account comply with the SFOX Terms of Service, and are in accordance with US law and standard banking (including ACH) guidelines"
},
"processing": {
"DISPLAY": "Pending Sell",