Skip to content

Instantly share code, notes, and snippets.

@byennen
Created December 10, 2010 03:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save byennen/735718 to your computer and use it in GitHub Desktop.
Save byennen/735718 to your computer and use it in GitHub Desktop.
Creating orders
def create
@order = Order.new(params[:order])
if @order.save
redirect_to(@order, :notice => 'Order was successfully created.')
else
render :action => "new"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment