app/models/city.rb in china_regions-1.0.3 vs app/models/city.rb in china_regions-1.0.4
- old
+ new
@@ -8,10 +8,10 @@
scope: [:province_id]
}
# Relationships
belongs_to :province, counter_cache: true
- delegate :name, to: :province
+ delegate :name, to: :province, prefix: true
has_many :districts, dependent: :destroy
# Fileters
scope :for_province, ->(province_id) { where(province_id: province_id) }