app/helpers/application_helper.rb
# Used in V2 to render all validation errors for a form
# form.error_messages and form.error_messages_for are deprecated in Rails 3
Used in V2 to render all validation errors for a form
form.error_messages and form.error_messages_for are deprecated in Rails 3
Used in V2 to render all validation errors for a form form . error_messages and form . error_messages_for are deprecated in Rails 3
def validation_errors_for(resource, message = nil)
    if resource.errors.any?
      message ||= I18n.t('activerecord.errors.template.header', count: resource.errors.size, model: '')
      capture_haml do
        haml_tag 'fieldset#errors' do
          haml_tag :legend, message
          haml_tag :ul do
            resource.errors.full_messages.each do |error|
              haml_tag :li, raw(error)
            end
          end
        end
      end
    end
  end
def validation_errors_for ( resource , message = nil ) if resource . errors . any? message ||= I18n . t ( 'activerecord.errors.template.header' , count : resource . errors . size , model : '' ) capture_haml do haml_tag 'fieldset#errors' do haml_tag :legend , message haml_tag :ul do resource . errors . full_messages . each do | error | haml_tag :li , raw ( error ) end end end end end end
Used in V2 to render all validation errors for a form
form.error_messages and form.error_messages_for are deprecated in Rails 3
Used in V2 to render all validation errors for a form form . error_messages and form . error_messages_for are deprecated in Rails 3
resource
<not_specific>
message
<not_specific>