Class: Country

Inherits:
ApplicationRecord show all
Defined in:
app/models/country.rb

Constant Summary collapse

CANADA_ID =
find_by(code: 'CA').country_id

Class Method Summary collapse

Methods inherited from ApplicationRecord

define_decrypted_attribute, define_decrypted_attributes, #errors_in_bullet_points, primary_connection, special_connection

Class Method Details

.canad_optionObject



8
9
10
# File 'app/models/country.rb', line 8

def canad_option
  select(:country_id, :description, :code).find(CANADA_ID)
end