Sha256: 25abb244adb0490c6b9c63dbe2a8896fdddfdf61d729160802bfd4fa8016f43a

Contents?: true

Size: 382 Bytes

Versions: 1

Compression:

Stored size: 382 Bytes

Contents

class County < ActiveRecordShared

	default_scope :order => :name
	has_many :zip_codes

	validates_presence_of :name
	validates_length_of   :name,         :maximum => 250
	validates_presence_of :state_abbrev
	validates_length_of   :state_abbrev, :maximum => 2
	validates_length_of   :fips_code,    :maximum => 5, :allow_nil => true

	def to_s
		"#{name}, #{state_abbrev}"
	end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
ccls-ccls_engine-3.11.0 app/models/county.rb