Module: PagesCore::PageModel::Images

Extended by:
ActiveSupport::Concern
Included in:
Page
Defined in:
app/models/concerns/pages_core/page_model/images.rb

Instance Method Summary collapse

Instance Method Details

#imageObject



33
34
35
# File 'app/models/concerns/pages_core/page_model/images.rb', line 33

def image
  super.try { |i| i.localize(locale) }
end

#image?Boolean

Returns:

  • (Boolean)


29
30
31
# File 'app/models/concerns/pages_core/page_model/images.rb', line 29

def image?
  image_id?
end

#imagesObject



37
38
39
# File 'app/models/concerns/pages_core/page_model/images.rb', line 37

def images
  super.in_locale(locale)
end

#page_imagesObject



41
42
43
# File 'app/models/concerns/pages_core/page_model/images.rb', line 41

def page_images
  super.in_locale(locale)
end