module ActionView::Helpers::ToCountrySelectCodeTag

Public Instance Methods

to_country_select_code_tag(priority_countries, options, html_options) click to toggle source
# File lib/country-select-code.rb, line 133
def to_country_select_code_tag(priority_countries, options, html_options)
  html_options = html_options.stringify_keys
  add_default_name_and_id(html_options)
  value = value(object)
  content_tag("select",
    add_options(
      country_options_for_select(value, priority_countries, options),
      options, value
    ), html_options
  )
end