work on comments
This commit is contained in:
@@ -1,22 +0,0 @@
|
||||
<article data-comment-id="<%= comment.id %>">
|
||||
<header>
|
||||
<h1><%= link_to comment.creator_name, user_path(comment.creator_id) %></h1>
|
||||
<time datetime="<%= comment.created_at %>"><%= time_ago_in_words(comment.created_at) %> ago</time>
|
||||
</header>
|
||||
<div>
|
||||
<section>
|
||||
<%= format_text(comment.body) %>
|
||||
</section>
|
||||
<footer>
|
||||
<menu>
|
||||
<li><span class="link">Quote</span></li>
|
||||
<% if CurrentUser.user.is_janitor? || CurrentUser.user.id == comment.creator_id %>
|
||||
<li><%= link_to "Delete", comment_path(comment.id), :confirm => "Do you really want to delete this comment?", :method => :delete %></li>
|
||||
<% end %>
|
||||
<li><%= link_to "Vote up", comment_vote_path(comment.id, :is_positive => true), :method => :post %></li>
|
||||
<li><%= link_to "Vote down", comment_vote_path(comment.id, :is_positive => false), :method => :post %></li>
|
||||
</menu>
|
||||
</footer>
|
||||
</div>
|
||||
</article>
|
||||
<div class="clearfix"></div>
|
||||
Reference in New Issue
Block a user