Sha256: a1ee6d75faebbc3fb92883cfcbbfe8482dd2e3e3c1e56dd7ba2c7a806be9f60c
Contents?: true
Size: 333 Bytes
Versions: 23
Compression:
Stored size: 333 Bytes
Contents
module Admin class City < ActiveRecord::Base include Carnival::ModelHelper self.table_name = "cities" belongs_to :country belongs_to :state scope :national, -> {includes(:country).where("countries.code = ?", "BR")} scope :international, -> {includes(:country).where("countries.code <> ?", "BR")} end end
Version data entries
23 entries across 23 versions & 1 rubygems