Class: ActiveadminSelleoCms::Image

Inherits:
Asset
  • Object
show all
Defined in:
app/models/activeadmin_selleo_cms/image.rb

Instance Attribute Summary collapse

Attributes inherited from Asset

#cover_resize_method

Instance Method Summary collapse

Methods inherited from Asset

#url

Instance Attribute Details

#cover_heightObject

Returns the value of attribute cover_height.



3
4
5
# File 'app/models/activeadmin_selleo_cms/image.rb', line 3

def cover_height
  @cover_height
end

#cover_widthObject

Returns the value of attribute cover_width.



3
4
5
# File 'app/models/activeadmin_selleo_cms/image.rb', line 3

def cover_width
  @cover_width
end

#image_heightObject

Returns the value of attribute image_height.



3
4
5
# File 'app/models/activeadmin_selleo_cms/image.rb', line 3

def image_height
  @image_height
end

#image_widthObject

Returns the value of attribute image_width.



3
4
5
# File 'app/models/activeadmin_selleo_cms/image.rb', line 3

def image_width
  @image_width
end

#resize_methodObject

Returns the value of attribute resize_method.



3
4
5
# File 'app/models/activeadmin_selleo_cms/image.rb', line 3

def resize_method
  @resize_method
end

Instance Method Details

#image_sizesObject



16
17
18
# File 'app/models/activeadmin_selleo_cms/image.rb', line 16

def image_sizes
  { :normal => "#{image_width || 640}x#{image_height || 480}#{resize_method || "#"}" }
end