Class: Superfaktura::Locales

Inherits:
Object
  • Object
show all
Defined in:
lib/superfaktura/locales.rb

Constant Summary collapse

LANGUAGES =
{
  en: 'eng',
  sk: 'slo',
  hu: 'hun',
  cs: 'cze',
  de: 'deu',
  hr: 'hrv',
  it: 'ita',
  pl: 'pol',
  ro: 'rom',
  ru: 'rus',
  sl: 'slv',
  es: 'spa',
  uk: 'ukr'
}.freeze

Class Method Summary collapse

Class Method Details

.iso2_to_iso3(iso2) ⇒ Object



19
20
21
# File 'lib/superfaktura/locales.rb', line 19

def self.iso2_to_iso3(iso2)
  LANGUAGES[iso2.to_sym] || 'eng'
end