Class: Formtastic::Inputs::JfuUploadInput

Inherits:
FileInput
  • Object
show all
Defined in:
lib/formtastic/inputs/jfu_upload_input.rb

Instance Method Summary collapse

Instance Method Details

#input_html_optionsObject



4
5
6
# File 'lib/formtastic/inputs/jfu_upload_input.rb', line 4

def input_html_options
  super.merge( class: 'jfu_upload_input' )
end

#to_htmlObject



8
9
10
11
12
13
14
15
16
# File 'lib/formtastic/inputs/jfu_upload_input.rb', line 8

def to_html
  input_wrapping do
    label_html <<
    template.( :div, { class: 'jfu_upload_wrapper' } ) do
      builder.file_field( method, input_html_options ) <<
      template.( :ul )
    end
  end
end