1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2025-01-17 06:52:27 +01:00

fix bug: cant show correct payment modal when pay by wallet and code promo

This commit is contained in:
Peng DU 2016-09-21 13:09:10 +02:00
parent cfd92cdc40
commit 1008a6dd1b

View File

@ -83,7 +83,7 @@ Application.Controllers.controller "PlansIndexController", ["$scope", "$rootScop
##
$scope.openSubscribePlanModal = ->
Wallet.getWalletByUser {user_id: $scope.ctrl.member.id}, (wallet) ->
amountToPay = helpers.getAmountToPay($scope.selectedPlan.amount, wallet.amount)
amountToPay = helpers.getAmountToPay($scope.cart.total, wallet.amount)
if $scope.currentUser.role isnt 'admin' and amountToPay > 0
payByStripe()
else