Parent

Methods

Files

Class/Module Index [+]

Quicksearch

SimpleForm::Inputs::NumericInput

Public Instance Methods

input() click to toggle source
# File lib/simple_form/inputs/numeric_input.rb, line 6
def input
  add_size!
  input_html_classes.unshift("numeric")
  if html5?
    input_html_options[:type] ||= "number"
    input_html_options[:step] ||= integer? ? 1 : "any"
  end
  @builder.text_field(attribute_name, input_html_options)
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.