Is there a mean to specify the messages order that are displayed by a
I see that we can specify the objects order. But what about the
messages related to a same object.
Let say I have an Order.
In my form I have the following order:
and in my model I have:
validates_presence_of :name, :address, :email, :pay_type
validates_format_of :email, :with => /\A([^@\s]+)@((?:[-a-z0-9]+.)+
However I get the following order for the error messages:
* Name can’t be blank
* Pay type can’t be blank
* Address can’t be blank
* Email is invalid
* Email can’t be blank
Obviously I would like the same order as in the form.
Is it possible with error_messages_for ?