Class: CafeCar::Inputs::FileInput
- Defined in:
- lib/cafe_car/inputs/file_input.rb
Overview
A file picker <input type="file"> for Active Storage attachments. A
has_many_attached field renders a multiple picker so several files upload
at once.
Instance Attribute Summary
Attributes inherited from BaseInput
#args, #form, #method, #options, #template
Instance Method Summary collapse
Methods inherited from BaseInput
build, classes, #html_safe?, #info, #initialize, #render_options, #text_hints, #to_html, #to_s
Constructor Details
This class inherits a constructor from CafeCar::Inputs::BaseInput
Instance Method Details
#defaults ⇒ Object
8 |
# File 'lib/cafe_car/inputs/file_input.rb', line 8 def defaults = info.multiple? ? { multiple: true } : {} |
#helper ⇒ Object
7 |
# File 'lib/cafe_car/inputs/file_input.rb', line 7 def helper = :file_field |