appeals: only show current appeal on appealed posts.
* Only show the current pending appeal in the "This post was appealed" notice. Don't show old appeals. * Don't show both the "This post was deleted" and the "This post was appealed" notice on appealed posts. Only show the "This post was appealed" notice. * Show "no reason" if no appeal reason was given.
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<% if post.is_deleted? %>
|
||||
<% if post.is_deleted? && !post.is_appealed? %>
|
||||
<div class="notice notice-small post-notice post-notice-deleted">
|
||||
<% if post.flags.any? %>
|
||||
<p>This post was deleted for the following reasons: </p>
|
||||
@@ -38,6 +38,7 @@
|
||||
This post was flagged and is pending approval (<%= link_to_wiki "learn more", "about:mod_queue" %>)
|
||||
<% elsif post.is_appealed? %>
|
||||
This post was appealed and is pending approval (<%= link_to_wiki "learn more", "about:mod_queue" %>)
|
||||
<%= render "post_appeals/reasons", appeal: post.appeals.select(&:pending?).last %>
|
||||
<% end %>
|
||||
|
||||
<%= render "post_disapprovals/counts", :disapprovals => post.disapprovals, :post => post %>
|
||||
@@ -49,14 +50,6 @@
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<% #XXX %>
|
||||
<% if post.is_deleted? && post.appeals.any? %>
|
||||
<div class="notice notice-small post-notice post-notice-appealed">
|
||||
<p>This post was appealed:</p>
|
||||
<%= render "post_appeals/reasons", appeals: post.appeals %>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<% if post.parent.present? %>
|
||||
<div class="notice notice-small post-notice post-notice-child">
|
||||
<%= render "posts/partials/show/parent_notice", parent: post.parent, children: @sibling_posts.to_a %>
|
||||
|
||||
Reference in New Issue
Block a user