Class: Ckeditor::Picture
- Inherits:
-
Asset
- Object
- ActiveRecord::Base
- Asset
- Ckeditor::Picture
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
included
Instance Method Details
#featured? ⇒ Boolean
7
8
9
|
# File 'app/models/ckeditor/picture.rb', line 7
def featured?
@featured ||= !contents_count.zero?
end
|
#pages ⇒ Object
11
12
13
|
# File 'app/models/ckeditor/picture.rb', line 11
def pages
@pages ||= contents.map(&:contentable).map(&:page).compact.uniq
end
|