Class: Mosaico::UploadedImage
- Defined in:
- app/models/mosaico/uploaded_image.rb
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Image
Class Method Details
.backend ⇒ Object
4 5 6 |
# File 'app/models/mosaico/uploaded_image.rb', line 4 def backend Mosaico::Engine.config.image_backend end |
Instance Method Details
#to_json ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'app/models/mosaico/uploaded_image.rb', line 9 def to_json { deleteType: 'DELETE', deleteUrl: url, name: file, originalName: file, size: filesize, thumbnailUrl: url, type: nil, url: url } end |
#url ⇒ Object
22 23 24 |
# File 'app/models/mosaico/uploaded_image.rb', line 22 def url Mosaico::Engine.routes.url_helpers.mosaico_image_path(self) end |