Module: ActionView::Helpers::CountrySelectTag

Included in:
InstanceTag, Tags::CountrySelect
Defined in:
lib/country-select.rb

Instance Method Summary collapse

Instance Method Details

#to_country_select_tag(priority_countries, options, html_options) ⇒ Object



295
296
297
298
299
300
301
302
303
304
305
# File 'lib/country-select.rb', line 295

def to_country_select_tag(priority_countries, options, html_options)
  html_options = html_options.stringify_keys
  add_default_name_and_id(html_options)
  ("select",

    add_options(
      country_options_for_select(value, priority_countries),
      options, value
    ), html_options
  )
end