Class: Asset

Inherits:
ActiveRecord::Base
  • Object
show all
Defined in:
app/models/asset.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#attachment_urlObject

Returns the value of attribute attachment_url.



8
9
10
# File 'app/models/asset.rb', line 8

def attachment_url
  @attachment_url
end

Instance Method Details

#image?Boolean

Returns:

  • (Boolean)


32
33
34
# File 'app/models/asset.rb', line 32

def image?
  !(attachment_content_type =~ /^image.*/).nil?
end

#to_sObject



36
37
38
# File 'app/models/asset.rb', line 36

def to_s
  attachment_file_name
end