20151221184633_create_billing_informations.rb 790 B

12345678910111213141516171819
  1. class CreateBillingInformations < ActiveRecord::Migration
  2. def change
  3. create_table :billing_informations do |t|
  4. t.belongs_to :customer, index:true, foreign_key: true
  5. t.string :name, null: false, limit: 255, default: ''
  6. t.string :rfc, null: false, limit: 13, default: ''
  7. t.string :address, null: false, limit: 255, default: ''
  8. t.integer :zipcode, null: false, default: 0
  9. t.string :num_ext, null: false, default: ''
  10. t.string :num_int, null: false, default: ''
  11. t.integer :state_id, index:true, null: false, default: 0
  12. t.integer :county_id, index:true, null: false, default: 0
  13. t.string :city, null: false, default: ''
  14. t.string :suburb, null: false, default: ''
  15. t.integer :status, null: false, default: 1
  16. t.timestamps null: false
  17. end
  18. end
  19. end