Files
grecia/app/views/shared/_errors.html.erb
2015-09-28 13:46:54 +02:00

15 lines
502 B
Plaintext

<% if resource.errors.any? %>
<div id="error_explanation" data-alert class="alert-box alert radius">
<a href="#" class="close" title="<%= t("application.close") %>">&times;</a>
<strong>
<%= pluralize resource.errors.count, t("form.error"), t("form.errors") %>
<% if local_assigns[:message].present? %>
<%= message %>
<% else %>
<%= t("form.not_saved", resource: t("form.#{resource.class.to_s.downcase}")) %>
<% end %>
</strong>
</div>
<% end %>