lib/formtastic/inputs/select_input.rb in formtastic-2.3.1 vs lib/formtastic/inputs/select_input.rb in formtastic-3.0.0.rc

- old
+ new

@@ -138,43 +138,19 @@ # # @todo Do/can we support the per-item HTML options like RadioInput? class SelectInput include Base include Base::Collections - include Base::GroupedCollections def to_html input_wrapping do - deprecated_hidden_input << label_html << - (options[:group_by] ? grouped_select_html : select_html) + select_html end end - # TODO: remove from Formtastic 3.0 - def deprecated_hidden_input - if multiple? && Util.rails3? && Util.deprecated_version_of_rails? - template.hidden_field_tag(input_html_options_name_multiple, '', :id => nil) - else - "".html_safe - end - end - def select_html builder.select(input_name, collection, input_options, input_html_options) - end - - def grouped_select_html - builder.grouped_collection_select( - input_name, - grouped_collection, - group_association, - group_label_method, - value_method, - label_method, - input_options, - input_html_options - ) end def include_blank options.key?(:include_blank) ? options[:include_blank] : (single? && builder.include_blank_for_select_by_default) end