fixes #2461: Mod queue comments
This commit is contained in:
@@ -41,6 +41,7 @@
|
||||
| <%= link_to "Breaks Rules", moderator_post_disapproval_path(:post_id => post.id, :reason => "breaks_rules"), :remote => true, :method => :post, :class => "disapprove-link" %>
|
||||
| <%= link_to "Poor Quality", moderator_post_disapproval_path(:post_id => post.id, :reason => "poor_quality"), :remote => true, :method => :post, :class => "disapprove-link" %>
|
||||
| <%= link_to "No Interest", moderator_post_disapproval_path(:post_id => post.id, :reason => "disinterest"), :remote => true, :method => :post, :class => "disapprove-link" %>
|
||||
| <%= link_to "Detailed Rejection", "#", "data-post-id" => post.id, :class => "detailed-rejection-link" %>
|
||||
</h2>
|
||||
</li>
|
||||
<li><strong>Rating</strong>: <%= post.pretty_rating %></li>
|
||||
@@ -60,16 +61,7 @@
|
||||
<li><strong>Appeals</strong>: <%= post_appeal_reasons(post) %></li>
|
||||
<% end %>
|
||||
<li>
|
||||
<strong>Hidden</strong>:
|
||||
<% if post.disapprovals.breaks_rules.exists? %>
|
||||
(breaks rules: <%= post.disapprovals.breaks_rules.count %>)
|
||||
<% end %>
|
||||
<% if post.disapprovals.poor_quality.exists? %>
|
||||
(poor quality: <%= post.disapprovals.poor_quality.count %>)
|
||||
<% end %>
|
||||
<% if post.disapprovals.disinterest.exists? %>
|
||||
(no interest: <%= post.disapprovals.disinterest.count %>)
|
||||
<% end %>
|
||||
<strong>Hidden</strong>: <%= render "post_disapprovals/compact_counts", :disapprovals => post.disapprovals %>
|
||||
</li>
|
||||
<li><strong>Tags</strong>: <%= post.tag_string %></li>
|
||||
</ul>
|
||||
@@ -82,6 +74,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<%= render "post_disapprovals/detailed_rejection_dialog" %>
|
||||
<%= render "posts/partials/common/secondary_links" %>
|
||||
|
||||
<% content_for(:page_title) do %>
|
||||
|
||||
17
app/views/post_disapprovals/_compact_counts.html.erb
Normal file
17
app/views/post_disapprovals/_compact_counts.html.erb
Normal file
@@ -0,0 +1,17 @@
|
||||
<% if disapprovals.count > 0 %>
|
||||
<% if disapprovals.breaks_rules.count > 0 %>
|
||||
(breaks rules: <%= disapprovals.breaks_rules.count %>)
|
||||
<% end %>
|
||||
|
||||
<% if disapprovals.poor_quality.count > 0 %>
|
||||
(poor quality: <%= disapprovals.poor_quality.count %>)
|
||||
<% end %>
|
||||
|
||||
<% if disapprovals.disinterest.count > 0 %>
|
||||
(no interest: <%= disapprovals.disinterest.count %>)
|
||||
<% end %>
|
||||
|
||||
<% if disapprovals.with_message.any? %>
|
||||
(messages: <%= disapprovals.disinterest.with_message.map(&:message).to_sentence %>)
|
||||
<% end %>
|
||||
<% end %>
|
||||
@@ -13,5 +13,9 @@
|
||||
<% if disapprovals.disinterest.count > 0 %>
|
||||
<%= disapprovals.disinterest.count %> did not like the post enough to approve it.
|
||||
<% end %>
|
||||
|
||||
<% if disapprovals.with_message.any? %>
|
||||
Messages: <%= disapprovals.with_message.map(&:message).to_sentence %>
|
||||
<% end %>
|
||||
</p>
|
||||
<% end %>
|
||||
@@ -0,0 +1,17 @@
|
||||
<div id="detailed-rejection-dialog" title="Detailed Rejection" style="display: none;">
|
||||
<%= form_tag(moderator_post_disapproval_path, :class => "simple_form", :id => "detailed-rejection-form") do %>
|
||||
<%= hidden_field_tag "post_id", "x" %>
|
||||
|
||||
<p>You can supply a short message to the uploader explaining why you rejected this upload.</p>
|
||||
|
||||
<div class="input">
|
||||
<label>Reason</label>
|
||||
<%= select_tag "reason", options_for_select([["Breaks Rules", "breaks_rules"], ["Poor Quality", "poor_quality"], ["No Interest", "disinterest"]]) %>
|
||||
</div>
|
||||
|
||||
<div class="input">
|
||||
<label>Message</label>
|
||||
<%= text_field_tag "message" %>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
@@ -43,7 +43,9 @@
|
||||
<% end %>
|
||||
<%= link_to "Breaks Rules", moderator_post_disapproval_path(:post_id => post.id, :reason => "breaks_rules"), :method => :post, :remote => true, :class => "btn" %> |
|
||||
<%= link_to "Poor Quality", moderator_post_disapproval_path(:post_id => post.id, :reason => "poor_quality"), :method => :post, :remote => true, :class => "btn" %> |
|
||||
<%= link_to "No Interest", moderator_post_disapproval_path(:post_id => post.id, :reason => "disinterest"), :method => :post, :remote => true, :class => "btn" %>
|
||||
<%= link_to "No Interest", moderator_post_disapproval_path(:post_id => post.id, :reason => "disinterest"), :method => :post, :remote => true, :class => "btn" %> |
|
||||
<%= link_to "Detailed Rejection", "#", "data-post-id" => post.id, :class => "detailed-rejection-link btn" %>
|
||||
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
@@ -76,3 +78,5 @@
|
||||
<span style="display: none;">Loading...</span>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<%= render "post_disapprovals/detailed_rejection_dialog" %>
|
||||
Reference in New Issue
Block a user