Class: Spree::Country
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- Spree::Country
- Defined in:
- app/models/spree/country.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.states_required_by_country_id ⇒ Object
10 11 12 13 14 15 16 |
# File 'app/models/spree/country.rb', line 10 def self.states_required_by_country_id states_required = Hash.new(true) self.all.each { |country| states_required[country.id.to_s]= country.states_required } states_required end |
Instance Method Details
#<=>(other) ⇒ Object
18 19 20 |
# File 'app/models/spree/country.rb', line 18 def <=>(other) name <=> other.name end |
#to_s ⇒ Object
22 23 24 |
# File 'app/models/spree/country.rb', line 22 def to_s name end |