Skip to content

Instantly share code, notes, and snippets.

@ornerymoose
Created May 4, 2012 21:07
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 ornerymoose/2597740 to your computer and use it in GitHub Desktop.
Save ornerymoose/2597740 to your computer and use it in GitHub Desktop.
= form_for @order, :url => {:action => "confirm"} do |f|
-if @order.errors.any?
#error_explanation
%h2= pluralize(@order.errors.count, "error") prohibited this order from being saved:
%ul
- @order.errors.full_messages.each do |msg|
%li= msg
.fields
= f.label :user_id
= f.number_field :user_id
.fields
= f.submit
@abhishekpillai
Copy link

at quick glancle, I would first try putting parantheses after form_for....like.....
form_for(@order, :url => {:action => "confirm"})

maybe?

what is the error you are getting with ur current code?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment