Sha256: 822422c45dd9bd237138f47add3724c93fd238540097abd0ad298285a7293ebd

Contents?: true

Size: 1020 Bytes

Versions: 2

Compression:

Stored size: 1020 Bytes

Contents

= cache [:admin, post] do
  = content_tag_for :tr, post, :"data-post-id" => post.id, :"data-state" => post.state, :"data-ready-for-review" => post.ready_for_review do
    td= post.title
    td= post.author_email
    td.span2.published-at = post.published_at.try(:to_s, :crowdblog_short)
    td.span1
      - if current_user.is_publisher?
        = link_to 'Publish', '#', :class => "btn btn-small publish-btn btn-danger #{(post.published? ? 'draft' : 'publish')}"
    td.span1
      .btn-group.states
        button.btn.btn-small.draft Drafted
        button.btn.btn-small.finish Finished
        - if !current_user.is_publisher?
          button.btn.btn-small.disabled.publish-status
        - if current_user.is_publisher?
          button.btn.btn-small.review Reviewed
    td.span1
      = link_to 'Delete', crowdblog.admin_post_path(post), :method => :delete, :confirm => 'Are you sure?', :class => "btn btn-small"
    td.span1
      = link_to 'Edit', crowdblog.edit_admin_post_path(post), :class => "btn btn-small"

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
crowdblog-0.3.3 app/views/crowdblog/admin/posts/_post.html.slim
crowdblog-0.4.0 app/views/crowdblog/admin/posts/_post.html.slim