Module: Shipyard::FormHelper

Defined in:
app/helpers/shipyard/form_helper.rb

Instance Method Summary collapse

Instance Method Details

#input_select_tag(name, choices, container_options = {}, select_options = {}) ⇒ Object



8
9
10
11
12
13
14
# File 'app/helpers/shipyard/form_helper.rb', line 8

def input_select_tag(name, choices, container_options={}, select_options={})
  container_options[:class] = "input-select-container #{container_options[:class]}"
   :div, container_options do
    select_options[:class] = "input input-select #{select_options[:class]}"
    select_tag name, choices, select_options
  end
end

#input_text(name, value = nil, options = {}) ⇒ Object



3
4
5
6
# File 'app/helpers/shipyard/form_helper.rb', line 3

def input_text(name, value=nil, options={})
  options[:class] = "input input-text #{options[:class]}"
  text_field_tag name, value, options
end