Module: AssetManager::CustomVersions
- Included in:
- AssetPublicUploader
- Defined in:
- lib/asset_manager/custom_versions.rb
Instance Method Summary collapse
Instance Method Details
#custom_versions ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/asset_manager/custom_versions.rb', line 4 def custom_versions version :thumb, if: :image? do process resize_and_pad: [50, 50] end version :show, if: :image? do process resize_and_pad: [300, 300] end version :thumb_pdf, if: :pdf? do process convert: :jpg process resize_to_fill: [230, 326] def full_filename(for_file = model.source.file) super.chomp(File.extname(super)) + '.jpg' end end end |