Sha256: 6f06e4f9a9626ff5fe852c6d66a5da93eb778bc938daf6703d3903ee249d0579

Contents?: true

Size: 594 Bytes

Versions: 8

Compression:

Stored size: 594 Bytes

Contents

class CreateBookings < ActiveRecord::Migration[5.1]
  def change
    create_table :bookings do |t|
      t.string :name, :null => false, limit: 256
      t.references :service, index: true

      t.string :email, null: true, limit: 256
      t.string :mobile, null: true, limit: 16

      t.date :date, :null => true
      t.string :time, null: true, limit: 16

      t.string :message, :limit=>1048

      t.boolean :featured, default: false
      t.string :status, :null => false, :default=>"new", :limit=>16
      t.timestamps null: false
    end

    add_index :bookings, :status
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
dhatu-0.1.25 db/migrate/20171104163661_create_bookings.rb
dhatu-0.1.24 db/migrate/20171104163661_create_bookings.rb
dhatu-0.1.23 db/migrate/20171104163661_create_bookings.rb
dhatu-0.1.22 db/migrate/20171104163661_create_bookings.rb
dhatu-0.1.21 db/migrate/20171104163661_create_bookings.rb
dhatu-0.1.20 db/migrate/20171104163661_create_bookings.rb
dhatu-0.1.19 db/migrate/20171104163661_create_bookings.rb
dhatu-0.1.18 db/migrate/20171104163661_create_bookings.rb