Class: Alchemy::EssenceFile Deprecated
- Inherits:
-
BaseRecord
- Object
- ActiveRecord::Base
- BaseRecord
- Alchemy::EssenceFile
- Defined in:
- app/models/alchemy/essence_file.rb
Overview
Deprecated.
Instance Method Summary collapse
- #attachment_url ⇒ Object
- #preview_text(max = 30) ⇒ Object
-
#serialized_ingredient ⇒ Object
Returns a serialized ingredient value for json api.
Instance Method Details
#attachment_url ⇒ Object
22 23 24 25 26 27 28 29 30 |
# File 'app/models/alchemy/essence_file.rb', line 22 def return if .nil? routes.( id: .id, name: .slug, format: .suffix, ) end |
#preview_text(max = 30) ⇒ Object
32 33 34 35 36 |
# File 'app/models/alchemy/essence_file.rb', line 32 def preview_text(max = 30) return "" if .blank? .name.to_s[0..max - 1] end |
#serialized_ingredient ⇒ Object
Returns a serialized ingredient value for json api
39 40 41 |
# File 'app/models/alchemy/essence_file.rb', line 39 def serialized_ingredient end |