Sha256: 8e6fa1498af6fa4a34a1bb0308c336ebcd1d01120349d429bfd0b05dc5d690c8

Contents?: true

Size: 596 Bytes

Versions: 7

Compression:

Stored size: 596 Bytes

Contents

class Admin::EffectivePollsDatatable < Effective::Datatable
  filters do
    scope :all
    scope :upcoming
    scope :available
    scope :completed
  end

  datatable do
    order :start_at, :desc

    col :token, visible: false
    col :created_at, visible: false
    col :updated_at, visible: false

    col :title
    col :start_at
    col :end_at
    col :audience

    col :poll_notifications
    col :poll_questions, visible: false

    col :hide_results, visible: false
    col :skip_logging, visible: false

    actions_col
  end

  collection do
    Effective::Poll.all.deep
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
effective_polls-0.7.3 app/datatables/admin/effective_polls_datatable.rb
effective_polls-0.7.2 app/datatables/admin/effective_polls_datatable.rb
effective_polls-0.7.1 app/datatables/admin/effective_polls_datatable.rb
effective_polls-0.7.0 app/datatables/admin/effective_polls_datatable.rb
effective_polls-0.6.2 app/datatables/admin/effective_polls_datatable.rb
effective_polls-0.6.1 app/datatables/admin/effective_polls_datatable.rb
effective_polls-0.6.0 app/datatables/admin/effective_polls_datatable.rb