about summary refs log tree commit diff stats
path: root/app/views/admin/comments/pending.haml
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/admin/comments/pending.haml')
-rw-r--r--app/views/admin/comments/pending.haml32
1 files changed, 32 insertions, 0 deletions
diff --git a/app/views/admin/comments/pending.haml b/app/views/admin/comments/pending.haml new file mode 100644 index 0000000..5352b12 --- /dev/null +++ b/app/views/admin/comments/pending.haml
@@ -0,0 +1,32 @@
1- title "Pending Comments"
2= will_paginate @comments
3= form_tag mass_admin_comments_url, method: :post do
4 #action-box
5 = select_tag "mass_action", options_for_select(["Delete", "Mark Spam"]), include_blank: true
6 = submit_tag "Mass action", data: { confirm: "Are you sure you want to do this action?" }
7 %table#entries
8 %tr
9 %th= check_box_tag "check_all"
10 %th Text
11 %th Author
12 %th Blog post
13 %th Date updated
14 %th
15 - @comments.each do |comment|
16 %tr{ class: cycle("even", "odd") }
17 %td= check_box_tag "comment_ids[]", comment.id, class: "comment_ids"
18 %td= comment.body
19 %td
20 %ul
21 %li= comment.username
22 %li= comment.email
23 - unless comment.website.empty?
24 %li= comment.website
25 %td= link_to comment.blog.title, comment.blog
26 %td= comment.created_at.strftime("%B %d, %Y, %l:%M%P")
27 %td
28 %ul.admin-actions
29 %li= link_to "Accept", accept_admin_comment_url(comment), method: :post, data: { confirm: "Are you sure you want to accept this comment?" }
30 %li= link_to "Reject", reject_admin_comment_url(comment), method: :post, data: { confirm: "Are you sure you want to reject this comment?" }
31 %li= link_to "Mark Spam", mark_spam_admin_comment_url(comment), method: :post, data: { confirm: "Are you sure you want to mark this comment as spam?" }
32= will_paginate @comments