Class: ContentItemPresenter

Inherits:
SimpleDelegator
  • Object
show all
Includes:
ContentImage
Defined in:
app/presenters/content_item_presenter.rb

Constant Summary

Constants included from ContentImage

ContentImage::DEFAULT_IMAGE, ContentImage::MISSING_WOOPLE_IMAGE

Instance Method Summary collapse

Methods included from ContentImage

#image

Instance Method Details

#certification_metadata {|source.certification_metadata| ... } ⇒ Object



7
8
9
# File 'app/presenters/content_item_presenter.rb', line 7

def (&block)
  yield(source.) if source..present?
end

#completed_classObject



11
12
13
# File 'app/presenters/content_item_presenter.rb', line 11

def completed_class
  'completed' if source.completed?
end

#sourceObject



15
16
17
# File 'app/presenters/content_item_presenter.rb', line 15

def source
  __getobj__
end