Skip to content

Instantly share code, notes, and snippets.

@rocodev-tech
Created June 13, 2014 03:58
Show Gist options
  • Save rocodev-tech/7658ef356f505ad5f881 to your computer and use it in GitHub Desktop.
Save rocodev-tech/7658ef356f505ad5f881 to your computer and use it in GitHub Desktop.
app/controllers/carts_controller.rb
class CartsController < ApplicationController
before_action :authenticate_user!, :only => [:checkout]
def index
end
def checkout
@order = current_user.orders.build
@info = @order.build_info
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment