cancel_return_url returns to checkout payment instead of edit order url

This commit is contained in:
Bounmy Stephane 2012-04-09 03:10:00 +02:00 committed by Ryan Bigg
parent ba2fc9d8c7
commit 4511907f4f
2 changed files with 2 additions and 2 deletions

View File

@ -252,7 +252,7 @@ module Spree
end end
opts = { :return_url => paypal_confirm_order_checkout_url(order, :payment_method_id => payment_method), opts = { :return_url => paypal_confirm_order_checkout_url(order, :payment_method_id => payment_method),
:cancel_return_url => edit_order_url(order), :cancel_return_url => edit_order_checkout_url(order, :state => :payment),
:order_id => order.number, :order_id => order.number,
:custom => order.number, :custom => order.number,
:items => items, :items => items,

View File

@ -256,7 +256,7 @@ module Spree
opts[:shipping].should == (order.ship_total * 100).to_i opts[:shipping].should == (order.ship_total * 100).to_i
opts[:return_url].should == spree.paypal_confirm_order_checkout_url(order, :payment_method_id => paypal_gateway.id, :host => "test.host") opts[:return_url].should == spree.paypal_confirm_order_checkout_url(order, :payment_method_id => paypal_gateway.id, :host => "test.host")
opts[:cancel_return_url].should == spree.edit_order_url(order, :host => "test.host") opts[:cancel_return_url].should == spree.edit_order_checkout_url(order, :state => 'payment', :host => "test.host")
opts[:items].size.should > 0 opts[:items].size.should > 0
opts[:items].size.should == order.line_items.count opts[:items].size.should == order.line_items.count