From 92646074a2788a8ed97fe699dc2ea9ee29e2dc6f Mon Sep 17 00:00:00 2001 From: ArtOfCode- Date: Tue, 5 Feb 2019 12:25:27 +0000 Subject: [PATCH] Permalink posts; close #573 --- app/views/posts/show.html.erb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/app/views/posts/show.html.erb b/app/views/posts/show.html.erb index dc594177c..7144b7998 100644 --- a/app/views/posts/show.html.erb +++ b/app/views/posts/show.html.erb @@ -11,10 +11,15 @@ " data-toggle="tooltip" data-placement="top" title="<%= (feedback.user.present? || feedback.api_key_id.present?) ? "#{feedback.user.try(:username)} (From #{feedback.api_key.try(:app_name) || "Review"})" : feedback.user_name %>: <%= feedback.feedback_type %>" class="<%= element_class_for_feedback feedback %>"><%= element_symbol_for_feedback(feedback).html_safe %> <% end %> + + <%= link_to post_path(@post) do %> + + <% end %> + <% unless feedbacks.empty? %> <% if current_user.present? && (current_user.has_role?(:admin) || @post.feedbacks.where(user_id: current_user.id).exists?) %> - <%= link_to "(clear)", clear_post_feedback_path(@post) %> + · <%= link_to "(clear)", clear_post_feedback_path(@post) %> <% end %> <% end %>