2010-08-31 21:53:30 +00:00
|
|
|
class EditableFile < EditableElement
|
|
|
|
|
2011-08-17 20:32:39 +00:00
|
|
|
localized_fields :source_filename
|
|
|
|
|
2010-08-31 21:53:30 +00:00
|
|
|
mount_uploader :source, EditableFileUploader
|
|
|
|
|
2011-08-17 20:32:39 +00:00
|
|
|
# localized_field :source
|
|
|
|
|
2010-08-31 21:53:30 +00:00
|
|
|
def content
|
|
|
|
self.source? ? self.source.url : self.default_content
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|