diff --git a/app/assets/stylesheets/specific/comments.css.scss b/app/assets/stylesheets/specific/comments.css.scss index 90a59d3e1..b49234f33 100644 --- a/app/assets/stylesheets/specific/comments.css.scss +++ b/app/assets/stylesheets/specific/comments.css.scss @@ -5,9 +5,10 @@ div.comments-for-post { margin: 1em 0; } - .info { + p.info { color: #AAA; font-style: italic; + font-size: 80%; } div.list-of-comments { diff --git a/app/assets/stylesheets/specific/forum.css.scss b/app/assets/stylesheets/specific/forum.css.scss index a1ed9162f..9c9461b25 100644 --- a/app/assets/stylesheets/specific/forum.css.scss +++ b/app/assets/stylesheets/specific/forum.css.scss @@ -1,4 +1,10 @@ div.list-of-forum-posts { + p.info { + color: #AAA; + font-style: italic; + font-size: 80%; + } + article { margin-bottom: 3em; diff --git a/app/models/forum_post.rb b/app/models/forum_post.rb index d31eda694..4ce71fb67 100644 --- a/app/models/forum_post.rb +++ b/app/models/forum_post.rb @@ -109,6 +109,10 @@ class ForumPost < ActiveRecord::Base def creator_name User.id_to_name(creator_id) end + + def updater_name + User.id_to_name(updater_id) + end def quoted_response stripped_body = body.gsub(/\[quote\](?:.|\n|\r)+?\[\/quote\][\n\r]*/m, "") diff --git a/app/views/comments/partials/show/_comment.html.erb b/app/views/comments/partials/show/_comment.html.erb index 039dfcf45..6f1a3f0e5 100644 --- a/app/views/comments/partials/show/_comment.html.erb +++ b/app/views/comments/partials/show/_comment.html.erb @@ -10,7 +10,7 @@ <%= format_text(comment.body) %> <% if comment.updater_id.present? && (comment.updater_id != comment.creator_id || comment.created_at != comment.updated_at) %> -

Updated by <%= link_to comment.updater_name, user_path(comment.updater_id) %> <%= time_ago_in_words_tagged(comment.updated_at) %>.

+

Updated by <%= link_to comment.updater_name, user_path(comment.updater_id) %> <%= time_ago_in_words_tagged(comment.updated_at) %>

<% end %> diff --git a/app/views/forum_posts/_forum_post.html.erb b/app/views/forum_posts/_forum_post.html.erb index 90bde396c..2a211abb6 100644 --- a/app/views/forum_posts/_forum_post.html.erb +++ b/app/views/forum_posts/_forum_post.html.erb @@ -15,6 +15,9 @@
<%= format_text(forum_post.body) %>
+ <% if forum_post.updated_at != forum_post.created_at %> +

Updated by <%= link_to forum_post.updater_name, user_path(forum_post.updater_id) %> <%= time_ago_in_words_tagged(forum_post.updated_at) %>

+ <% end %>
  • ID: <%= forum_post.id %>
  • <% if @forum_topic %> diff --git a/app/views/posts/partials/show/_information.html.erb b/app/views/posts/partials/show/_information.html.erb index dc01c8e02..1d0dfa1ce 100644 --- a/app/views/posts/partials/show/_information.html.erb +++ b/app/views/posts/partials/show/_information.html.erb @@ -14,7 +14,7 @@
  • Source: <%= post_source_tag(post) %>
  • Rating: <%= post.pretty_rating %>
  • Score: <%= post.score %> <% if CurrentUser.is_privileged? %>(vote <%= link_to "up", post_votes_path(:post_id => post.id, :score => "up"), :remote => true, :method => :post %>/<%= link_to "down", post_votes_path(:post_id => post.id, :score => "down"), :remote => true, :method => :post %>)<% end %>
  • -
  • Fav count: <%= post.fav_count %>
  • +
  • Favorites: <%= post.fav_count %>
  • Status: <% if post.is_pending? %>