Sha256: 2eab41c35ae9e0492fd3bd5586c0125b1b052a1922259a80a567b198e9e80d1e
Contents?: true
Size: 968 Bytes
Versions: 79
Compression:
Stored size: 968 Bytes
Contents
json.records do json.array!(@comments) do |comment| json.extract!(comment, :id, :author, :author_email, :commentable_type, :commentable_id, :content) json.gravatar gravatar_for(comment) if comment.commentable.posted? && route_exist?(comment.commentable) json.commentable_link link_to("#{comment.commentable.title}", main_app.polymorphic_path(comment.commentable), :target => "_") else json.commentable_link comment.commentable.title end json.read_link action_link("Read", '#', 'eye', 'data-modal-target' => "#comment-#{comment.id}", 'data-modal-title' => 'Read Comment') json.approval_link toggle_link(comment, 'approved', toggle_approved_comment_path(comment), ['thumbs-up', 'Approved'], ['thumbs-down', 'Not Approved']) json.delete_link delete_link(comment) end end json.pagination do json.currentPage @comments.current_page json.totalPages @comments.total_pages json.totalEntries @comments.total_entries end
Version data entries
79 entries across 79 versions & 1 rubygems