Class: Ckeditor::Picture

Inherits:
Asset
  • Object
show all
Defined in:
app/models/ckeditor/picture.rb

Constant Summary

Constants inherited from Asset

Asset::SIZE_RANGE

Instance Method Summary collapse

Methods inherited from Asset

#extension, #to_jq_upload

Methods included from Georgia::Indexer

included

Instance Method Details

#featured?Boolean



7
8
9
# File 'app/models/ckeditor/picture.rb', line 7

def featured?
  @featured ||= !contents_count.zero?
end

#pagesObject



11
12
13
# File 'app/models/ckeditor/picture.rb', line 11

def pages
  @pages ||= contents.map(&:contentable).map(&:page).compact.uniq
end