fix setting parent_id, add approval status notices on top of post/show
This commit is contained in:
@@ -1,6 +1,16 @@
|
||||
<% if @post.errors.any? %>
|
||||
|
||||
Danbooru.error("Error: " + <%= @post.errors.full_messages.join("; ").to_json.html_safe %>);
|
||||
|
||||
<% else %>
|
||||
|
||||
$("#c-posts #approve").hide();
|
||||
$("#c-posts #disapprove").hide();
|
||||
$("#c-posts #flag").show();
|
||||
|
||||
$("#pending-approval-notice").hide();
|
||||
|
||||
$("#c-post-moderation #post-<%= @post.id %>").hide();
|
||||
Danbooru.notice("Post was approved");
|
||||
Danbooru.notice("Post was approved");
|
||||
|
||||
<% end %>
|
||||
@@ -1,12 +1,14 @@
|
||||
<% if @post_disapproval.errors.any? %>
|
||||
|
||||
Danbooru.j_error("Error: " + "<%= j @post_disapproval.errors.full_messages.join("; ") %>");
|
||||
Danbooru.error("Error: " + <%= @post_disapproval.errors.full_messages.join("; ").to_json.html_safe %>);
|
||||
|
||||
<% else %>
|
||||
|
||||
$("#c-posts #approve").hide();
|
||||
$("#c-posts #disapprove").hide();
|
||||
|
||||
$("#pending-approval-notice").hide();
|
||||
|
||||
$("#c-post-moderation #post-<%= @post.id %>").hide();
|
||||
Danbooru.notice("Post was disapproved");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user