Sha256: 36676e7b76f0afdf398940a0eb722a29a45abf99391bbfa2d473eb02bad1c667

Contents?: true

Size: 894 Bytes

Versions: 4

Compression:

Stored size: 894 Bytes

Contents

class PhotoPresenter < Carnival::BaseAdminPresenter
  field :id,
    actions: [:index, :show, :csv, :pdf],
    searchable: true,
    sortable: true,
    advanced_search: {operator: :equal}
  field :title,
    actions: [:index, :new, :edit, :show, :csv, :pdf],
    searchable: true,
    sortable: true,
    advanced_search: {operator: :like}
  field :image,
    actions: [:new, :edit, :show],
    as: :admin_previewable_file
  field :person,
    actions: [:index, :new, :edit, :show, :csv, :pdf],
    searchable: true,
    sortable: true,
    advanced_search: {operator: :equal}
  field :updated_at,
    actions: [:index, :show, :csv, :pdf],
    sortable: true,
    advanced_search: {operator: :between}
  field :created_at,
    actions: [:index, :show, :csv, :pdf],
    sortable: true,
    advanced_search: {operator: :between}

  action :new
  action :edit
  action :show
  action :destroy
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
carnival-0.1.3 test/carnival-sample-application/app/presenters/photo_presenter.rb
carnival-0.1.2 test/carnival-sample-application/app/presenters/photo_presenter.rb
carnival-0.1.1 test/carnival-sample-application/app/presenters/photo_presenter.rb
carnival-0.1.0 test/carnival-sample-application/app/presenters/photo_presenter.rb