Sha256: 314988456838675e2f0430cf7977e9ee1940e7df72709573365b3c77d865b32f
Contents?: true
Size: 1.4 KB
Versions: 12
Compression:
Stored size: 1.4 KB
Contents
# == Schema Information # # Table name: addresses # # id :integer not null, primary key # street1 :string(255) # street2 :string(255) # city :string(64) # state :string(64) # zipcode :string(16) # country :string(64) # full_address :string(255) # address_type :string(16) # addressable_id :integer # addressable_type :string(255) # created_at :datetime # updated_at :datetime # deleted_at :datetime # <% require "ffaker" puts "Loading addresses..." type = %w(Billing Shipping) addressable = %w(Account Contact Lead) for i in (1 .. rand(200) + 200) do %> address_<%= i %>: id : <%= i %> addressable_id : <%= i/2 %> addressable_type : <%= asset = addressable.sample %> address_type : <%= asset == 'Account' ? type.sample : 'Business' %> street1 : <%= street1 = Faker::Address.street_address %> street2 : <%= street2 = Faker::Address.street_address %> city : <%= city = Faker::Address.city %> state : <%= state = Faker::Address.us_state_abbr %> zipcode : <%= zipcode = Faker::Address.zip_code %> country : US full_address : | <%= street1 %> <%= street2 %> <%= "#{city}, #{state} #{zipcode}" %> US <% end %>
Version data entries
12 entries across 12 versions & 1 rubygems