Class: Cardboard::Field::File
- Inherits:
-
Cardboard::Field
- Object
- ActiveRecord::Base
- Cardboard::Field
- Cardboard::Field::File
- Defined in:
- app/models/cardboard/field/file.rb
Instance Attribute Summary
Attributes inherited from Cardboard::Field
Instance Method Summary collapse
Methods inherited from Cardboard::Field
new_with_castnew, #required?, #type, #type=
Instance Method Details
#value ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'app/models/cardboard/field/file.rb', line 9 def value return nil unless value_uid if value_uid =~ /^app\/assets\/files/ Dragonfly.app.fetch_file(value_uid) else Dragonfly.app.fetch(value_uid) end end |