Sha256: 0e3b90efa551ae3a5b885a81475e85b983c3df91d97a350d90a1f4021620ae10

Contents?: true

Size: 676 Bytes

Versions: 2

Compression:

Stored size: 676 Bytes

Contents

class CreateItems < ActiveRecord::Migration[5.0]
  def change
    create_table :items, id: :uuid, default: 'gen_random_uuid()' do |t|
      t.string :call_number
      t.string :item_identifier
      t.timestamps
      t.datetime :deleted_at
      t.references :shelf, default: 1
      t.boolean :include_supplements, default: false, null: false
      t.text :note
      t.string :url
      t.integer :price
      t.integer :lock_version, default: 0, null: false
      t.integer :required_role_id, default: 1, null: false
      t.integer :required_score, default: 0, null: false
    end
    add_index :items, :item_identifier
    add_index :items, :required_role_id
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
enju_seed-0.3.0.beta.4 spec/dummy/db/migrate/006_create_items.rb
enju_seed-0.3.0.beta.3 spec/dummy/db/migrate/006_create_items.rb