Sha256: acf2aa2d9557b53ab52f652a432506db3a1f6b53e417012be9c2ef7c354df228

Contents?: true

Size: 550 Bytes

Versions: 1

Compression:

Stored size: 550 Bytes

Contents

require "jobshop/helpers/migration.rb"

class CreateOrganizations < ActiveRecord::Migration[5.1]
  include Jobshop::Helpers::Migration

  def change
    create_table :jobshop_organizations, id: false do |t|
      t.uuid :organization_id, null: false, default: "gen_random_uuid()"
      t.index :organization_id, unique: true,
        name: :idx_jobshop_organizations_pkey

      t.citext :name, index: true
      t.index [ :organization_id, :name ], unique: true

      t.timestamps
    end

    idx_table_name_pkey "jobshop_organizations"
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
jobshop-0.0.157 db/migrate/20171216021339_create_organizations.rb