forked from tomash/spree-pp-website-standard
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
some more cleanup and tweaking. still not there, but pretty usable ATM
- Loading branch information
Showing
4 changed files
with
64 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# commented-out as this is too invasive at the moment | ||
# (assumes paypal is the only payment method available in your store) | ||
|
||
=begin | ||
CheckoutController.class_eval do | ||
def edit | ||
if (@order.valid? && @order.state == "payment") | ||
puts "valid, processing" | ||
if @order.payable_via_paypal? | ||
puts "payable via paypal, adding payment" | ||
payment = Payment.new | ||
payment.amount = @order.total | ||
payment.payment_method = Order.paypal_payment_method | ||
@order.payments << payment | ||
payment.started_processing | ||
render(:partial => 'checkout/paypal_checkout') | ||
end | ||
end | ||
end | ||
end | ||
=end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters