Sha256: 738b10fc7c3031848c5d4db942ad1d879641e32037c7588bcf5263f99a2edd5b

Contents?: true

Size: 325 Bytes

Versions: 10

Compression:

Stored size: 325 Bytes

Contents

class AddStates < ActiveRecord::Migration
  def self.up
    %w(AL AK AZ AR CA CO CT DE DC FL GA HI ID IL IN IA KS KY LA ME MD MA MI MN MS MO MT NE NV NH NJ NM NY NC ND OH OK OR PA RI SC SD TN TX UT VT VA WA WV WI WY).each do |s|
      State.new(:name => s).save
    end
  end

  def self.down
    State.destroy_all
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
community_engine-3.2.0 db/migrate/014_add_states.rb
community_engine-3.0.0 db/migrate/014_add_states.rb
community_engine-2.3.2 db/migrate/014_add_states.rb
community_engine-2.3.1 db/migrate/014_add_states.rb
community_engine-2.3.0 db/migrate/014_add_states.rb
community_engine-2.1.0 db/migrate/014_add_states.rb
community_engine-2.0.0 db/migrate/014_add_states.rb
community_engine-2.0.0.beta3 db/migrate/014_add_states.rb
community_engine-2.0.0.beta2 db/migrate/014_add_states.rb
community_engine-2.0.0.beta1 db/migrate/014_add_states.rb