delete action from post/show requires confirmation+flag reason now

This commit is contained in:
albert
2013-02-23 16:53:03 -05:00
parent 138f3eb3db
commit 4a61498f0e
5 changed files with 27 additions and 7 deletions

View File

@@ -0,0 +1,15 @@
<h1>Delete Post</h1>
<div>
<%= PostPresenter.preview(@post) %>
</div>
<%= form_tag(delete_moderator_post_post_path, :style => "clear: both;", :class => "simple_form") do %>
<div class="input">
<label for="reason">Reason</label>
<%= text_area_tag "reason" %>
</div>
<%= submit_tag "Delete" %>
<%= submit_tag "Cancel" %>
<% end %>

View File

@@ -1,4 +0,0 @@
$("#c-posts #delete").hide();
$("#c-posts #undelete").show();
$("#c-post-moderation #post-<%= @post.id %>").remove();
Danbooru.notice("Post was deleted");