From a64642956561908cdbdb40fea24d3891e4cc9391 Mon Sep 17 00:00:00 2001 From: Tom Naessens Date: Tue, 9 Dec 2014 13:41:35 +0100 Subject: [PATCH] Use decent bootstrap errors --- app/views/application/_errors.html.erb | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/app/views/application/_errors.html.erb b/app/views/application/_errors.html.erb index d7c0fb2..6a3452e 100644 --- a/app/views/application/_errors.html.erb +++ b/app/views/application/_errors.html.erb @@ -1,5 +1,14 @@ - +<% if model.errors.any? %> +
+
+ <%= pluralize(model.errors.count, "error") %> prohibited this <%= model.class.name.downcase %> from being saved: +
+
+
    + <% model.errors.full_messages.each do |msg| %> +
  • <%= msg %>
  • + <% end %> +
+
+
+<% end %>