Skip to content

Commit

Permalink
fixes #2731 'add spam button,line 16 _answers.html.erb' (#2785)
Browse files Browse the repository at this point in the history
* add spam button,line 16 _answers.html.erb

* changed comment.ids to answer.ids

* changed from comment path to answer

* changed comment.parent.path to answer.path

* some more cleanup to the button

* change answer.aid to answer id
  • Loading branch information
rtrunkhill authored and jywarren committed Jun 7, 2018
1 parent 5597698 commit e56cf45
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions app/views/questions/_answer.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@
<a style="color:#aaa;" href="#a<%= answer.id %>"><%= time_ago_in_words(answer.created_at) %> ago</a>
</div>
<div class="navbar-text pull-right">
<a rel="tooltip" title="Flag as spam" class="btn btn-sm btn-default btn-flag-spam-<%= answer.id %>" href="mailto:moderators@publiclab.org?subject=Reporting+spam+on+Public+Lab&body=Hi,+I+found+this+comment+that+looks+like+spam+or+needs+to+be+moderated:+https://publiclab.org/<%= answer.node.path %>#a<%= answer.id %>+by+https://publiclab.org/profile/<%= answer.author.username %>+Thanks!">
<i class="fa fa-flag"></i>
</a>
<% if current_user && answer.uid == current_user.uid %>
<a class="btn btn-default btn-sm" href="javascript:void(0)" onClick="$('#c<%= answer.id %>edit').toggle();$('#c<%= answer.id %>show').toggle();setInit(<%= answer.id %>);"><i class="fa fa-pencil"></i></a>
<% end %>
Expand Down

0 comments on commit e56cf45

Please sign in to comment.