Class: Archangel::TimePickerInput

Inherits:
SimpleForm::Inputs::Base
  • Object
show all
Defined in:
app/inputs/archangel/time_picker_input.rb

Overview

Time picker custom input for SimpleForm

Instance Method Summary collapse

Instance Method Details

#input(wrapper_options = nil) ⇒ Object

Build input field


13
14
15
16
17
18
# File 'app/inputs/archangel/time_picker_input.rb', line 13

def input(wrapper_options = nil)
  merged_input_options =
    merge_wrapper_options(input_html_options, wrapper_options)

  @builder.text_field(attribute_name, merged_input_options)
end

#input_html_classesObject

Add `timepicker` as an HTML class


23
24
25
# File 'app/inputs/archangel/time_picker_input.rb', line 23

def input_html_classes
  super.push("timepicker")
end