Class: MultiValueInput
- Inherits:
-
SimpleForm::Inputs::CollectionInput
- Object
- SimpleForm::Inputs::CollectionInput
- MultiValueInput
- Defined in:
- app/inputs/multi_value_input.rb
Instance Method Summary collapse
Instance Method Details
#input(wrapper_options) ⇒ Object
2 3 4 5 6 7 8 9 10 11 12 13 14 |
# File 'app/inputs/multi_value_input.rb', line 2 def input() @rendered_first_element = false input_html_classes.unshift('string') [:name] ||= "#{object_name}[#{attribute_name}][]" outer_wrapper do buffer_each(collection) do |value, index| inner_wrapper do build_field(value, index) end end end end |