Sha256: dd1fba1047f9bc6418fb61a73f5e5494fcf57a5d5d8d7e8fb40cea2836fd5e6c

Contents?: true

Size: 534 Bytes

Versions: 4

Compression:

Stored size: 534 Bytes

Contents

if defined?(EffectiveDatatables)
  module Effective
    module Datatables
      class Posts < Effective::Datatable
        table_column :published_at

        table_column :id

        table_column :title
        table_column :category, :filter => {:type => :select, :values => EffectivePosts.categories }

        table_column :draft

        table_column :actions, :sortable => false, :filter => false, :partial => '/admin/posts/actions'

        def collection
          Effective::Post.all
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
effective_posts-0.2.2 app/models/effective/datatables/posts.rb
effective_posts-0.2.1 app/models/effective/datatables/posts.rb
effective_posts-0.2.0 app/models/effective/datatables/posts.rb
effective_posts-0.1.2 app/models/effective/datatables/posts.rb