All Projects β†’ zooppa β†’ administrate-field-carrierwave

zooppa / administrate-field-carrierwave

Licence: MIT license
🌊 A plugin to upload and preview Carrierwave attachments in Administrate

Programming Languages

ruby
36898 projects - #4 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to administrate-field-carrierwave

administrate-field-jsonb
A plugin to show and edit JSON objects within Administrate.
Stars: ✭ 38 (+137.5%)
Mutual labels:  administrate
carrierwave-cloudflare
πŸŽ‘ This Rails gem integrates Carrierwave with Cloudflare Image Resizing
Stars: ✭ 24 (+50%)
Mutual labels:  carrierwave
administrate-field-paperclip
Paperclip field plugin for Administrate
Stars: ✭ 14 (-12.5%)
Mutual labels:  administrate
carrierwave-attachmentscanner
Adds the ability to send CarrierWave uploads to Attachment Scanner for virus and malware prevention.
Stars: ✭ 14 (-12.5%)
Mutual labels:  carrierwave
carrierwave-dropbox
Carrierwave storage for Dropbox
Stars: ✭ 67 (+318.75%)
Mutual labels:  carrierwave

Administrate::Field::Carrierwave

Build status Code Climate

A plugin to upload and preview Carrierwave attachments in Administrate.


IMPORTANT NOTICE

This gem is not actively maintained anymore.

If you’re interested in taking over and steward the project moving forward, please get in touch.


Usage

Add it to your Gemfile:

gem 'administrate-field-carrierwave', '~> 0.6.0'

Run:

$ bundle install

Add to your FooDashboard:

ATTRIBUTE_TYPES = {
  bar: Field::Carrierwave.with_options(
    image: :standard,
    multiple: true,
    remove: false,
    remote_url: false
  )
}.freeze

To handle multiple asset uploads, the attribute must point to an empty array in a hash:

# If multiple: true
def permitted_attributes
  super - [:bar] + [{ bar: [] }]
end

Options

  • image (default: nil): a version that will be displayed in an <img> element.
  • multiple (default: false): allows uploading of multiple files. ATTENTION 🚨: requires CarrierWave’s master branch. Uploaded files will replace the current ones – if present – and not add to them.
  • remove (default: false): allow to remove previously uploaded files. ATTENTION 🚨 extend permitted_attributes by remove_FIELD
  • remote_url (default: false): allow uploading files from a remote location. ATTENTION 🚨 extend permitted_attributes by remote_FIELD_url

About

Administrate::Field::Carrierwave is maintained by Zooppa.

See also the list of contributors who participated in this project.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].