Create a report_link helper, and use text instead of a flag icon
This commit is contained in:
parent
ee1a8637d3
commit
32d1afbb18
7 changed files with 22 additions and 22 deletions
|
@ -17,17 +17,16 @@
|
|||
<br/>
|
||||
<%= note_event(@note.status, @note.closed_at, @note_comments.last.author) %>
|
||||
<% end %>
|
||||
<% if current_user && current_user != @note.author %>
|
||||
<%= link_to new_report_url(reportable_id: @note.id, reportable_type: @note.class.name), :title => t('browse.note.report') do %>
|
||||
⚐
|
||||
<% end %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<% if @note_comments.find { |comment| comment.author.nil? } -%>
|
||||
<p class='warning'><%= t "javascripts.notes.show.anonymous_warning" %></p>
|
||||
<% end -%>
|
||||
|
||||
<% if current_user && current_user != @note.author %>
|
||||
<p class="deemphasize"><%= report_link(t(".report"), @note) %></p>
|
||||
<% end %>
|
||||
|
||||
<% if @note_comments.length > 1 %>
|
||||
<div class='note-comments'>
|
||||
<ul>
|
||||
|
|
|
@ -2,9 +2,7 @@
|
|||
<%= user_thumbnail diary_comment.user %>
|
||||
<p class="deemphasize comment-heading" id="comment<%= diary_comment.id %>"><%= raw(t('diary_entry.diary_comment.comment_from', :link_user => (link_to h(diary_comment.user.display_name), :controller => 'user', :action => 'view', :display_name => diary_comment.user.display_name), :comment_created_at => link_to(l(diary_comment.created_at, :format => :friendly), :anchor => "comment#{diary_comment.id}"))) %>
|
||||
<% if current_user and diary_comment.user.id != current_user.id %>
|
||||
<%= link_to new_report_url(reportable_id: diary_comment.id, reportable_type: diary_comment.class.name), :title => t('diary_entry.diary_comment.report') do %>
|
||||
⚐
|
||||
<% end %>
|
||||
| <%= report_link(t(".report"), diary_comment) %>
|
||||
<% end %>
|
||||
</p>
|
||||
|
||||
|
|
|
@ -6,12 +6,6 @@
|
|||
|
||||
<h2><%= link_to h(diary_entry.title), :action => 'view', :display_name => diary_entry.user.display_name, :id => diary_entry.id %></h2>
|
||||
|
||||
<% if current_user and diary_entry.user != current_user %>
|
||||
<%= link_to new_report_url(reportable_id: diary_entry.id, reportable_type: diary_entry.class.name), :title => t('diary_entry.diary_entry.report') do %>
|
||||
⚐
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<small class='deemphasize'>
|
||||
<%= raw(t 'diary_entry.diary_entry.posted_by', :link_user => (link_to h(diary_entry.user.display_name), :controller => 'user', :action => 'view', :display_name => diary_entry.user.display_name), :created => l(diary_entry.created_at, :format => :blog), :language_link => (link_to h(diary_entry.language.name), :controller => 'diary_entry', :action => 'list', :display_name => nil, :language => diary_entry.language_code)) %>
|
||||
</small>
|
||||
|
@ -37,6 +31,12 @@
|
|||
<%= link_to t('diary_entry.diary_entry.edit_link'), :action => 'edit', :display_name => diary_entry.user.display_name, :id => diary_entry.id %>
|
||||
<% end %>
|
||||
|
||||
<% if current_user and diary_entry.user != current_user %>
|
||||
<li>
|
||||
<%= report_link(t(".report"), diary_entry) %>
|
||||
</li>
|
||||
<% end %>
|
||||
|
||||
<%= if_administrator(:li) do %>
|
||||
<%= link_to t('diary_entry.diary_entry.hide_link'), hide_diary_entry_path(:display_name => diary_entry.user.display_name, :id => diary_entry.id), :method => :post, :data => { :confirm => t('diary_entry.diary_entry.confirm') } %>
|
||||
<% end %>
|
||||
|
|
|
@ -104,9 +104,7 @@
|
|||
|
||||
<% if current_user and @this_user.id != current_user.id %>
|
||||
<li>
|
||||
<%= link_to new_report_url(reportable_id: @this_user.id, reportable_type: @this_user.class.name), :title => t('user.view.report') do %>
|
||||
⚐
|
||||
<% end %>
|
||||
<%= report_link(t(".report"), @this_user) %>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue