Commit 50de1caf

mo k <mo@mokhan.ca>
2012-06-14 13:48:07
remove 'Error', 'Notice' heading from alert section.
1 parent 9d3bc0b
Changed files (3)
app/controllers/comments_controller.rb
@@ -7,7 +7,7 @@ class CommentsController < ApplicationController
 
   def create
     command_for(CommentOnCreationCommand).run(params)
-    flash[:notice] = params[:comment][:body]
+    flash[:notice] = "Nice Comment!"
     redirect_to :controller => 'creations', :action => 'show', :id => params[:creation_id]
   end
 end
app/views/layouts/_messages.html.erb
@@ -6,17 +6,10 @@
         <% Array(value).uniq.each do |message| -%>
         <div class="alert alert-<%= key %>">
           <a class="close" data-dismiss="alert" href="#">×</a>
-          <h4 class="alert-heading"><%= key.to_s.titleize -%>!</h4>
+          <!-- <h4 class="alert-heading"><%= key.to_s.titleize -%>!</h4> -->
           <%= message %>
         </div>
         <% end -%>
-        <!--
-        <div class="alert alert-<%= key %>">
-          <a class="close" data-dismiss="alert" href="#">×</a>
-          <h4 class="alert-heading"><%= key.to_s.titleize -%>!</h4>
-          <%= value %>
-        </div>
-        -->
       <% end -%>
     </div>
   </div>
app/views/shared/_creation_image_gallery.html.erb
@@ -8,11 +8,7 @@
       </div>
       <a href="<%= url_for creation %>"><img src="<%= creation.image.thumb.url %>" alt="<%= creation.name %>" rel="nofollow" width="260" /></a>
       <div class="caption">
-        <% if creation.favorites.count > 0 %>
-          <span> <a href="<%= url_for creation_favorites_path(:creation_id => creation.id) %>"><%= creation.favorites.count %><i class="icon-heart"></i></a> </span>
-        <% else %>
-          <span>&nbsp;</span>
-        <% end %>
+        <a href="<%= url_for creation_favorites_path(:creation_id => creation.id) %>"><span><%= creation.favorites.count %><i class="icon-heart"></span></i></a>
         <a href="<%= url_for creation %>#comments"><span class="badge badge-success" title="<%= pluralize( creation.comment_threads.count, "comments") %>"><%= creation.comment_threads.count %></span></a>
       </div>
     </div>