Class: I18n::Backend::ActiveRecord::Translation
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- I18n::Backend::ActiveRecord::Translation
- Defined in:
- lib/active_support/vendor/i18n-0.4.1/i18n/backend/active_record/translation.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.available_locales ⇒ Object
74 75 76 |
# File 'lib/active_support/vendor/i18n-0.4.1/i18n/backend/active_record/translation.rb', line 74 def self.available_locales Translation.find(:all, :select => 'DISTINCT locale').map { |t| t.locale.to_sym } end |
Instance Method Details
#interpolates?(key) ⇒ Boolean
78 79 80 |
# File 'lib/active_support/vendor/i18n-0.4.1/i18n/backend/active_record/translation.rb', line 78 def interpolates?(key) self.interpolations.include?(key) if self.interpolations end |