I have the following scenario and am trying to find the best way to
I have an Order model which accepts a customers billing & shipping
address, order info and order item details.
I have a store_controller which currently has a checkout action and a
1. I have one template / page (checkout.html.erb) with a form for the
customer to enter their billing and shipping info.
2. I need another template / page which based on the customers country
selection in the previous page displays the correct currency and
calculates the correct VAT or Tax info. This will update and display
the cart totals. The customer will also on this page enter in their
credit card info and submit for order processing.
Here's where I have the question.
As you can see I need to break up my checkout page into two pages.
One for billing and shipping info, and one for the final checkout
confirmation and the customer to enter their credit card info. After
the credit card is authorized this would all get submitted to the
Order model for validation and saving.
I have done this plenty of times in the past but not in Rails and
wanted to try and find a "rails way" to solve this.
How would you tackle this problem?
Thanks very much.