fixes #706
This commit is contained in:
@@ -49,7 +49,7 @@ module ApplicationHelper
|
||||
instance = instance_variable_get("@#{instance_name}")
|
||||
|
||||
if instance && instance.errors.any?
|
||||
%{<div class="error-messages ui-state-error ui-corner-all"><span class="ui-icon ui-icon-alert"></span> <strong>Error</strong>: #{instance.__send__(:errors).full_messages.join(", ")}</div>}.html_safe
|
||||
%{<div class="error-messages ui-state-error ui-corner-all"><strong>Error</strong>: #{instance.__send__(:errors).full_messages.join(", ")}</div>}.html_safe
|
||||
else
|
||||
""
|
||||
end
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
<div id="a-edit">
|
||||
<h1>Edit Comment</h1>
|
||||
|
||||
<%= error_messages_for "comment" %>
|
||||
|
||||
<%= simple_form_for(@comment) do |f| %>
|
||||
<%= dtext_field "comment", "body" %>
|
||||
<%= f.button :submit, "Submit" %>
|
||||
|
||||
Reference in New Issue
Block a user